23 May '13 - 07:22 *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
 
   Home   Help Search Login Register  
Pages: [1]
  Reply  |  Print  
Author Topic: OS X: entering fullscreen stops music  (Read 1049 times)
trentgg
Guest
« on: 27 Apr '12 - 17:21 »
Reply with quoteQuote

When I go to enter fullscreen mode (set window style and call enterFullscreenMode on NSView), my music stops. Restarting it results in 1 second of playback followed by it stopping again. If I start off in fullscreen mode, when I start the music, it plays for 1 second then stops. I get the following output to console:

kernelErrorToOSStatus: OSStatus = -1 (error = 14)
kernelErrorToOSStatus: OSStatus = -1 (error = 14)

(yes, repeated twice)

I'm running OS X 10.7. Any ideas?
Logged
Ian @ un4seen
Administrator
Posts: 15269


« Reply #1 on: 27 Apr '12 - 17:58 »
Reply with quoteQuote

Could you provide a little example project to reproduce the problem with? If so, it can be uploaded here...

   ftp.un4seen.com/incoming/
Logged
trentgg
Guest
« Reply #2 on: 27 Apr '12 - 19:37 »
Reply with quoteQuote

I uploaded a project as bassex.zip. It's just some sample code taken from a tutorial and slightly modified. So if you run this in xcode, you should hear some music start playing, then the opengl context is created at which point the music stops (so it seems opengl related, as my program is also using opengl.) That's even before you enter fullscreen mode. So I believe it has something to do with opengl but I'm not sure what. The error I get as I stated in my first message is described as:

Mac OS error 14 (dsIOCoreErr): IO Core Error

By the macerror command line tool. I believe if you start the music after opengl context creation, it'll play but if you toggle fullscreen mode it'll stop again.
Logged
Ian @ un4seen
Administrator
Posts: 15269


« Reply #3 on: 30 Apr '12 - 15:08 »
Reply with quoteQuote

Thanks for the test project. Unfortunately, there appears to be some files missing (eg. AppDelegate.m/h) which is preventing it building. Could you include them too please?
Logged
trentgg
Guest
« Reply #4 on: 30 Apr '12 - 15:47 »
Reply with quoteQuote

Try the new project, bassex3.zip. Sorry about that.
Logged
Ian @ un4seen
Administrator
Posts: 15269


« Reply #5 on: 30 Apr '12 - 17:21 »
Reply with quoteQuote

Thanks, it's building fine now. It also seems to be running fine, ie. the music continues playing after the "Lesson02" window comes up. That's on an OSX 10.6 system though, rather than 10.7. I notice that you're using BASS 2.4.7 in the project. Please try upgrading to 2.4.8 (it includes an OSX 10.7 compatibility fix), and let me know if the problem continues then.
Logged
trentgg
Guest
« Reply #6 on: 30 Apr '12 - 19:49 »
Reply with quoteQuote

It's an odd thing. I did try using 2.4.8 but had the same problem. I ran the test again before I uploaded just a couple hours ago and the music stopped. Now forgetting all about this issue, I needed to test my game on OS X, so I built it and now it runs fine even when toggling fullscreen off and on over and over. So I'm not sure what happened. I've made a few minor fixes to the game since but no memory errors or anything I could consider related to the problem. But anyway, may have just been an intermittent problem because everything runs fine now! If I find it happening again I'll try and come up with some better test case, but for now we're all good Smiley.
Logged
korruptor
Posts: 2


« Reply #7 on: 9 May '12 - 11:37 »
Reply with quoteQuote

Just to let you know, I've seen this problem as well while running 2.4.8 under OS X 10.7.

I've just ported my game framework to run under glfw. BASS throws out:

kernelErrorToOSStatus: OSStatus = -1 (error = 14)
kernelErrorToOSStatus: OSStatus = -1 (error = 14)

Just after the Init call.

The game will be unstable past this point, with what looks like a threading issue causing a crash. I've not been able to debug any further than this and may be wrong about the threading issue, but removing BASS allows glfw and my test to run perfectly.

 
Logged
Ian @ un4seen
Administrator
Posts: 15269


« Reply #8 on: 9 May '12 - 16:46 »
Reply with quoteQuote

BASS doesn't output anything to the console itself, so those messages will be coming from something else, probably the OS. If you are able to reproduce the problem, I could send you a debug version to try to locate what the problem is.
Logged
trentgg
Guest
« Reply #9 on: 10 Jun '12 - 22:04 »
Reply with quoteQuote

Resurrecting this thread... I'm not 100% sure but I think the problem only happens when debugging the app in Xcode. When I export it it works. I'll try a debug lib if you like still, though.

(And apologies about not testing that Android 3.2 bug further, but we found the issue anyway. His tablet with Android 3.1, for some reason, didn't have OpenSL at all. He upgraded to 3.2 and now has OpenSL. So I just check if BASS init fails and use my fallbacks if so.)
Logged
Oleg N
Posts: 8


« Reply #10 on: 7 Jul '12 - 16:10 »
Reply with quoteQuote

As far as I discovered this happens on Lion (does not on 10.6),  in XCode 4 in debug mode, only in 64-bit configuration. in 32-bit mode my app works well in debug build.

My app uses Bass To Record sound, the same problem happens after recording starts,  right in time when GUI shows up.
Logged
Pages: [1]
  Reply  |  Print  
 
Jump to:  

Powered by SMF 1.1.18 | SMF © 2013, Simple Machines