screensaver on mac?
BlitzMax Forums/BlitzMax Programming/screensaver on mac?
| ||
does anyone know how to convert a windows screensaver done in blitzmax to apple mac? |
| ||
Yeah... start with not using BlitzMax :-p |
| ||
D'oh! |
| ||
You have a stable screensaver shell for Windows in Blitzmax? :) |
| ||
there was some code posted, but after looking at it... it doesnt work! |
| ||
Been discussed a few times, it's quite difficult. Basically you have to write the screensaver in XCode and use their `framework` API, write the code in objective c, and then compile it in XCode. We could not really figure out how to get BlitzMax involved even a little bit, otherwise I would've churned out many a screensaver by now. It's nowhere near as easy as renaming an exe on the PC, although that's not all there is to it. It's hard to get the windows preview working properly too. |
| ||
It's hard to get the windows preview working properly too. Nah...There's a stable Windows screen saver example in the archives. |
| ||
I tried some code I found on this website and the preview worked fine, the actual screensaver just failed to appear on the screen but stayed in memory |
| ||
If you really want to make Mac screensavers you can use Quartz Composer, whci you can find on your hard disk in /Developer/applications/graphics tools/Quartz composer.app It's quite fun to play around with anyway. Cheers Charlie |
| ||
Yah I tried that and made a simple one... but the dream is to use BlitzMax with OpenGL or DX to make your own screensaver... a bit more difficult on the Mac. |
| ||
jkrankie, do you know if quartz composer can launch an external executable? |
| ||
what if you make an app that runs in the background until there is no input for a certain amount of time, and then brings itself to the front after that amount of time. |
| ||
what if you make an app that runs in the background until there is no input for a certain amount of time, and then brings itself to the front after that amount of time. Hehehe... :-) |
| ||
That's what I asked in Brucey's other thread. It's how it used to be done before there was a centralized screensaver system in osx or windows. Maybe its the only option for integrating Blitz or Unity code into a screensaver on osx. The question is, how do you monitor all system input from a blitz program so that you know when to trigger the saver? |
| ||
Just thought I'd mention that a proper screen saver for mac is currently impossible from bmax. Screen savers under 10.6 must be 64bit. BMax only generates 32bit. So fundamentally it's impossible to make a proper screen saver from bmax for the current release of OS X. Workarounds are the only real option such as a screen saver launcher, i.e. a screen saver that just runs another program, and quits it when the screen saver ends. It's not a clean solution for something distributable, but it might be enough if you you just want something for yourself etc. |
| ||
So you're saying all 32-bit screensavers which would've worked on leopard suddenly stop working on snow leopard? My question again is... does anyone know how to monitor global system input so that you can trigger a screensaver manually? |
| ||
My question again is... does anyone know how to monitor global system input so that you can trigger a screensaver manually? You do realize this is a really bad idea, don't you? |
| ||
You do realize this is a really bad idea, don't you? my fault for suggesting it :p why is it a really bad idea though? its not like it would take up any cpu time with a delay 200 in there ;) then check for any keys hit or mousehits/movement every 200 millisecs... |
| ||
why is it a really bad idea though? You're bypassing the system in use by Mac OS that allows it to conserve battery use/system resources/what have you. Your proposed solution would use more battery, more resources, and it would do all this regardless of whether or not it was even running. That aside, it's an intuitively bad idea - I shouldn't have to explain that going around the operating system's method for this is bad (nevermind that users who want to have a password to disable the screensaver would be completely unable to use your screensaver thanks to its hack).There's also the rather obvious issue of whether or not you can trust something that is monitoring all user input regardless of whether or not it's the main/key window. |
| ||
re:ImaginaryHuman yes, if you try to use a 32 bit screen saver in 10.6 it will say it's not compatible and tell you to contact the developer for an updated version. A bit vague, but official http://support.apple.com/kb/TS2913 And for lack of a better reference handy see http://www.macintouch.com/specialreports/snowleopard/slcompat.html Second paragraph, last sentence. |
| ||
@nilium oh I guess that makes sense.. I never really used my screensavers like that because I work on a windows machine and its as easy as renaming it and using some code in the code archives |
| ||
You do have some points. I guess Mac screensavers are just going to remain off limits. The only other idea I had was to use Quartz Composer to create a basic screensaver which uses the `command line` plugin to launch an external executable as the screensaver... only issue then is the preview window isn't going to show the proper screensaver, you still have to create a configuration panel in Interface Builder using probably Objective C code or something, and the Quartz Composer screensaver will probably cause two screens to be open or something. There just is no easy way of doing it other than using Apple's dedicated system, writing the saver entirely in Objective C using their framework. |
| ||
It's doable in C++/Obj-C ... and therefore should also be possible in bmx2 (I'd imagine)... |
| ||
Probably technically there is a way, but it seems so difficult. Also now as someone else said, Snow Leopard requires screensavers to be 64-bit, so Blitz is currently totally out of the picture. |
| ||
Apart from some of the obvious drabacks/concerns about a custom external input monitor, isn't there some way to properly use the o/s to handle such monitoring in a safe way? |