Wow, this was fast... congratulations! Just want to say that VLC is a separate project and it's version for ProjectM really sucks, just a couple of poor visuals and jerking logo on the screen. Goom visuals for VLC are far better. Anyway, would there be any controls for changing presets in your plugin? You know... random or hand driven? Again, respect!
Posted Fri 21 Oct 11 @ 11:12 am
Run into a few things:
Offscreen buffers in OpenGL aren't hardware accelerated under windows - they fallback onto software rendering. Yuck. Hidden window seems to be the way to go.
Plugin has controls currently for:
Hard cut sensitivity
Transition duration
Preset time
Shuffle on/off
Manual jump to next preset (obviously next random one if shuffle is enabled)
I've got some changes to make to the rendering method as it slows down quite a bit during some preset changes. Lets face it though it's not exactly an optimal method:
Render projectM to windows OpenGL back buffer
Switch buffers
Read pixels from buffer
Lock DirectX texture
Convert OpenGL pixels format to DirectX pixel format for each pixel
Unlock DirectX texture
Render DirectX texture
For simplicitys sake at the moment I've stuck all that into one render routine - however I need to break it apart and convince OpenGL contexts to play nice!
For anyone reading who may be concerned about licensing (projectM is licensed under the LGPL) that I've made my code compliant by way of a small wrapper class. The projectM sources needed fettling too as the win32 project appears to be targetted to v1.x whereas I'm using projectM v2.
Offscreen buffers in OpenGL aren't hardware accelerated under windows - they fallback onto software rendering. Yuck. Hidden window seems to be the way to go.
Plugin has controls currently for:
Hard cut sensitivity
Transition duration
Preset time
Shuffle on/off
Manual jump to next preset (obviously next random one if shuffle is enabled)
I've got some changes to make to the rendering method as it slows down quite a bit during some preset changes. Lets face it though it's not exactly an optimal method:
Render projectM to windows OpenGL back buffer
Switch buffers
Read pixels from buffer
Lock DirectX texture
Convert OpenGL pixels format to DirectX pixel format for each pixel
Unlock DirectX texture
Render DirectX texture
For simplicitys sake at the moment I've stuck all that into one render routine - however I need to break it apart and convince OpenGL contexts to play nice!
For anyone reading who may be concerned about licensing (projectM is licensed under the LGPL) that I've made my code compliant by way of a small wrapper class. The projectM sources needed fettling too as the win32 project appears to be targetted to v1.x whereas I'm using projectM v2.
Posted Fri 21 Oct 11 @ 11:51 am
OK it's a little smoother now I've threaded things. Still a slowdown on this machine when changing between some presets though. Might just be this machine which has had some oddities in the past so will test another tomorrow.
Any slowdown is likely to either be glReadPixels(), LockRect() or PM itself actually slowing down. I might have a play with PBOs to see if I can speed up glReadPixels().
Any slowdown is likely to either be glReadPixels(), LockRect() or PM itself actually slowing down. I might have a play with PBOs to see if I can speed up glReadPixels().
Posted Fri 21 Oct 11 @ 12:41 pm
Got an collection of 110 easy and smooth presets, chosen for Boxee player. If you want to try them, there you go:
http://www.mediafire.com/?o9g55qeutz8kf69
http://www.mediafire.com/?o9g55qeutz8kf69
Posted Fri 21 Oct 11 @ 12:51 pm
O.K. so maybe you will get the M-proj effects working?....goonna rename it ...huh...the SB project?...;-p
Posted Sun 23 Oct 11 @ 7:25 pm
Well had a chance earlier today to do a little more work on this. I tested it on the gig laptop and it worked but pegged the CPU at 100% (2.8GHz Core2Extreme).
Some optimisations has now seen that drop massively to around 20-30% instead.
Touch wood so far I've had no crashes or freezes so all being well I might be running it at my gig tonight.
Some optimisations has now seen that drop massively to around 20-30% instead.
Touch wood so far I've had no crashes or freezes so all being well I might be running it at my gig tonight.
Posted Sat 29 Oct 11 @ 9:53 am
Well it seems to be stable, but once sized suitably for TV output it was quite a CPU hog on my gig system - just then OpenGL rendering of projectM was taking around 50% CPU, as opposed to 11% at the same resolution on this machine.
Posted Sun 30 Oct 11 @ 2:29 pm
Yes, I've seen it already... connecting to Full HD TV's made my laptop's CPU go nuts. When connecting to HD Ready TV's... smooth and easy CPU. Maybe to wait for 1920x1080 laps? ;-)
Posted Sun 30 Oct 11 @ 4:07 pm
My laptop is 1920x1200 anyway.
Running 800x600 was enough to get 50% CPU usage!
Be interesting to see what my new laptop makes of it.
Running 800x600 was enough to get 50% CPU usage!
Be interesting to see what my new laptop makes of it.
Posted Tue 01 Nov 11 @ 7:51 am
Naaah, I wish i could help you more, but I can't. I just don't like those freezings, I could blame it on DirectX, but I couldn't care less about it. Still think the best way is over flash plugins, but time will tell. Best luck...
Posted Thu 03 Nov 11 @ 11:27 am
No freezings in PM, just high CPU usage which is caused by the projectM rendering which is all OpenGL - no DirectX, so I'm not sure what your comment meant!
Posted Thu 03 Nov 11 @ 11:54 am
All VDJ plugins are frozen in some point, when you connect to second screen, TV, whatever. It doesn't mean it will freeze always, but if you start a few more plugins to play in the same time... it will freeze anyway. Check it out. It's not connected to your thread, it just happens from time to time. And it's the reason why I'm still NLU ;-).
Posted Thu 03 Nov 11 @ 12:09 pm
I've never had that issue, I can and do run multiple video plugins at the same time with no freezes.
Posted Thu 03 Nov 11 @ 5:32 pm
Just found this, in XNTH's stuff:
Although virtually any size AVI can be used, because of 3D hardware performance considerations, a power-of-two dimension is preferred. Since every non-power-of-two video frame must be internally re-sized to a power-of-two resolution first, AVIs rendered to one of the following resolutions bypass this step and perform much better:
• 256x256
• 512x512
• 1024x1024
Hope it would help (ignore that AVI).
Although virtually any size AVI can be used, because of 3D hardware performance considerations, a power-of-two dimension is preferred. Since every non-power-of-two video frame must be internally re-sized to a power-of-two resolution first, AVIs rendered to one of the following resolutions bypass this step and perform much better:
• 256x256
• 512x512
• 1024x1024
Hope it would help (ignore that AVI).
Posted Wed 09 Nov 11 @ 4:50 am
I'm already rendering at POW2 sizes ;)
Posted Wed 09 Nov 11 @ 12:41 pm
Milkdrops are created with lower resolutions in mind, back in time it was luxury to get 800x600... maybe it needs total optimisation of the main (milkdrop) code, even there are softwares that shows it in window or widescreen as an plugin (SSP Media player, MPlayer).
Posted Fri 16 Dec 11 @ 4:25 am
I'm not a newbie at this ;)
Besides I've tried varying resolutions - even 800x600 was quite taxing for a 2.8GHz Core2Extreme/nVidia 8800GTX. Didn't stress my desktop system at all though.
Also bear in mind that I'm discussing projectM ;)
Besides I've tried varying resolutions - even 800x600 was quite taxing for a 2.8GHz Core2Extreme/nVidia 8800GTX. Didn't stress my desktop system at all though.
Also bear in mind that I'm discussing projectM ;)
Posted Fri 16 Dec 11 @ 4:52 am
Ah, so there's a difference? ;-) Sorry, didn't noticed. Also, you should bear in mind there are copyrights on presets, made by various people, even the ProjectM is free. It's hard to get this stuff working without them. But, one could manage it out without a hassle (renaming the extension) :
http://i44.tinypic.com/w1fud3.jpg
http://i44.tinypic.com/w1fud3.jpg
Posted Fri 16 Dec 11 @ 5:28 am
Not an issue for me - I won't be distributing presets outside of those included with projectM - which is a few hundred IIRC.
Posted Fri 16 Dec 11 @ 8:53 am
Scott is this your first rodeo, lol!! Can't wait for whatever you've got up your sleeve. Don't forget I'm always ready to test out things for ya.
Patiently Waiting
Huey
Patiently Waiting
Huey
Posted Fri 16 Dec 11 @ 9:04 am