pouët.net

Mac OS X demomaking, need help

category: code [glöplog]
I've got a bug on my Macbook with OS X Lion and latest Xcode:
Quartz Composer freezes while adding a new timeline into "Timelines" path.
Can anybody make a test project: a single "Timeline" path with 5 or more timelines inside it, please? I'll copy it to my project then.
Thanks!
added on the 2011-08-11 13:08:43 by Manwe Manwe
It's not "freezing", there's just a stupid bug where it asks you for the name. Type something, press return, and it magically works again :)

http://www.interealtime.com/timelines.qtz
added on the 2011-08-11 13:17:06 by psonice psonice
And btw, kineme.net is super awesome for QC discussion, plugins, etc.
added on the 2011-08-11 13:17:52 by psonice psonice
Thanks maali, I just called and donated to support your continued treatment :D
added on the 2011-08-11 15:12:42 by psonice psonice
great. now i can buy a mac too!
Thanks, psonice! You saved the World (or Demoscene at least).
Now I'm going to kineme.net, looking for OGG/MP3 plyback QC plugin.
added on the 2011-08-11 17:03:13 by Manwe Manwe
manwe: use the movie importer patch, connect the output to a billboard (it can be offscreen of course :) so it gets rendered. Then go into the settings, set it to asynchronous. One mp3 player :) It'll give you track position information too.

OGG probably won't work without perian installed, which isn't useful for a demo. It's probably better to use AAC anyway, it'll give you better quality at lower bit-rates and the OS supports it natively.
added on the 2011-08-11 17:46:03 by psonice psonice
Thank you for idea!
Trying to make a perfect sync between music and visuals, I found the following trick:
convert music to MOV with any video stream (low fps and resolution), because "Movie Importer" patch returns "track position" ONLY for video stream. Then send "track position" to Timelines input (turn external source in its settings).
It works!
added on the 2011-08-11 19:26:47 by Manwe Manwe
Yep :) Btw, have a dig into the .app package for http://www.pouet.net/prod.php?which=50146 and http://www.pouet.net/prod.php?which=51652 for useful tips ;)
added on the 2011-08-11 21:02:10 by psonice psonice
Think I remember what I did now. Use an mp3 like I described before. Set the movie importer to external time. Now you can forget the track position completely and use patch time to drive the movie player. The patch time IS the track time. Better still you can use the range patch on the time to loop any section of the demo, this fucking rules when your're syncing a section near the end :D
added on the 2011-08-12 00:22:43 by psonice psonice
Hmm, I can't see timeline base parameter for Movie Importer parch. Only Timeliner patch can be switched to external/local/patent.
added on the 2011-08-12 20:30:35 by Manwe Manwe
Just checked, you're right. Timebase can only set if it's not on asynchronous, but then you get no audio. Check my old demos, see how I did it :)
added on the 2011-08-12 20:50:36 by psonice psonice
Also make a wonderful effect \o/
added on the 2011-08-12 22:50:09 by Photon Photon
Trying to compile my first composition (as it described in QC Programming Guide) I found the build runs only on a few machines. Others shows a black screen. Then I used QuartzBuilder 1.2 but that machines shows even transparent windows instead of black.
These guys wrote in readme they used a "wrapper" to compile their demo. Have any idea what it can be?
I use latest Xcode on OS X Lion. Macbook 2008 (MB403).
added on the 2011-08-16 10:58:00 by Manwe Manwe
Transparent windows is a feature, not a bug ;) It lets you make stuff that shows the desktop below. Put a Clear patch in the top level of your comp, set the clear colour to solid black.

I'd ask on kineme about the compatibility issue, the guys there will be able to help. Does the composition itself run on the macs where the app fails? (This is pretty rare but possible - e.g. using 16bit render targets only works on ATI cards).
added on the 2011-08-16 11:07:32 by psonice psonice
Curious about that 'wrapper' they used for that demo too - it doesn't look like quartz builder, unless that creates custom classes and builds the app from scratch (I'd have though it would just bundle the .qtz and a plist to tell it how to launch, but maybe not?) Maybe they just mean they made an app to wrap the composition in a basic QCRenderer?
added on the 2011-08-16 11:15:13 by psonice psonice
I dont know how they made it, but iam think it was just a simple quartz composer view. Here is a screenshot of my little test in xcode with a simple cocoa application.

No changes has been made to the source, i just added the view and loaded the qtz. Make sure you clicked on autostart movie. Get a fullscreen window should not be the problem, there are tons of examples for cocoa.

BB Image
added on the 2011-08-16 13:38:20 by Ish Ish
Sry for the second post, but i added the wrong picture :(

BB Image
added on the 2011-08-16 13:39:18 by Ish Ish
Wow, they fixed that! It used to fail to load the composition or something. Anyway, been a while since I read up on this, but I seem to remember QCRenderer being the way to go for best performance, you set up an openGL context (or use the convenient openGL view in interface builder..) and render into that. It's quite easy, and there's some good examples on apple's site.
added on the 2011-08-16 15:16:58 by psonice psonice
Hmm, clear color was set to transparent in my composition. I fixed it now.
Can anybody test the app on his Mac, please?
Download 440 kb (qtz file also included).
added on the 2011-08-16 15:48:10 by Manwe Manwe
Yep, works fine windowed. (I'm on lion, maybe I can find a 10.6 or 10.5 box to try it on tomorrow if you're worried about compatibility).
added on the 2011-08-16 15:59:34 by psonice psonice
Thanks, psonice! 10.6 compatibility is still important, check it if you can, please.
BTW, how much FPS shows this test app on your machine?
added on the 2011-08-16 16:41:15 by Manwe Manwe
Quote:
....but I seem to remember QCRenderer being the way to go for best performance, you set up an openGL context (or use the convenient openGL view in interface builder..) and render into that


I thought that QCView has its own openGl context.
Look for openGL in this document:
http://developer.apple.com/library/mac/#documentation/GraphicsImaging/Reference/QuartzFramework/Classes/QCView_Class/Reference/Reference.html
added on the 2011-08-16 16:41:51 by Ish Ish
manwe: 30-40. I'm on a radeon 2600. I'm getting 45-50fps in the .qtz, fullscreen at 1920x1200. You can optimise that plenty, I replaced the gauss blur with a CICheapBlur, and set the render-in-image to 8bit/no mip-mapping and got 95fps fullscreen with no noticeable loss of quality.

Isha: Yeah, it does, but I seem to remember it comes with some performance downside somewhere. Also with your own context it's possible to enable AA and the likes.
added on the 2011-08-16 17:14:55 by psonice psonice

login