Intel® Integrated Performance Primitives
Deliberate problems developing high-performance vision, signal, security, and storage applications.
6706 Discussions

simple_player, adding DX render window, what's missing from given code?

noemata
Beginner
625 Views
I'm trying to add a DX render window to simpler_player, but there is some basic detail I'm missing. I've attached the tweaked version of simpler_player.cpp which features a secondary window for rendering video content.

What are the missing ingrediants?

(look for TRYDXRENDER in code)

Oops, just noticed that line 698 should be: cc.ulVideoRenderFlags = UMC::FLAG_VREN_USECOLORKEY;
0 Kudos
8 Replies
pvonkaenel
New Contributor III
625 Views
Quoting - noemata
I'm trying to add a DX render window to simpler_player, but there is some basic detail I'm missing. I've attached the tweaked version of simpler_player.cpp which features a secondary window for rendering video content.

What are the missing ingrediants?

(look for TRYDXRENDER in code)

Oops, just noticed that line 698 should be: cc.ulVideoRenderFlags = UMC::FLAG_VREN_USECOLORKEY;



Hello again,

You were very very close - I just had to disable a couple other blocks of code to get your window to work.

Peter
0 Kudos
noemata
Beginner
625 Views
Quoting - pvonkaenel



Hello again,

You were very very close - I just had to disable a couple other blocks of code to get your window to work.

Peter

I think you may have meant to upload a different file. Either that, or your not running on Vista, or I'm working with a video file that is problematic.

Commenting out this line (~ line727):

GetClientRect(Context.m_hWnd,cc.rectDisp,cc.rectRange);

Wouldn't that prevent the render widow from working, since its render rect would be 0,0,0,0?

Also, the file you uploaded didn't have this line (~ line 699):

cc.ulVideoRenderFlags = UMC::FLAG_VREN_USECOLORKEY;

I guess there's something I don't understand still. Based on your changes, it looks like the DX render feature is somehow able to find the renderwindow based on it's color key onlywithout knowing the window rect details since your changes load 0,0,0,0 for those values??

The code prior to your changes should work since the values were correct in that instance (I think).

Thanks for your help nonetheless, you're getting me close to having this working.

Mario
0 Kudos
noemata
Beginner
625 Views
Well, looks like DirectDraw under Vista is a lot more fun (as in not so) than it is under XP. Overlay handling code that works under XP, fails under Vista.

Still haven't cracked this nut, but the issue has been reduced to constructing code that works for both XP and Vista.


0 Kudos
pvonkaenel
New Contributor III
625 Views
Quoting - noemata
Well, looks like DirectDraw under Vista is a lot more fun (as in not so) than it is under XP. Overlay handling code that works under XP, fails under Vista.

Still haven't cracked this nut, but the issue has been reduced to constructing code that works for both XP and Vista.



Sorry, you're correct that I'm working with XP. Good to know there is an issue with this code working under Vista. I'll let you know if I discover anything during my next round of development.

Peter
0 Kudos
andrei_m
Beginner
625 Views
Try using BLTVideoRender it is far more stable under XP and likely it will work under Vista, unfortunately it was removed in 6.0, but still can be downloaded from IPP 5.3 sample package.
0 Kudos
noemata
Beginner
625 Views
Quoting - andrei.m
Try using BLTVideoRender it is far more stable under XP and likely it will work under Vista, unfortunately it was removed in 6.0, but still can be downloaded from IPP 5.3 sample package.

Thank you for the suggestion. It works with my secondary windowchanges to simple_player as originally posted, though there is a window sizing issue that needs tweaking. Vista can now show a playback window! Why is Intel so quiet on this thread?
0 Kudos
Vladimir_Dudnik
Employee
625 Views
Hello all.

Sorry for delay.Just want to set the right level of expectations regarding IPP audio-video-codecs sample.

This sample is dedicated to demonstrate how one can get performance advantages on modern Intel architectures through Intel IPP usage in media codecs and hardware friendly codecs design. Itis not considered as a comprehensive media framework and this is the reason why we do not provide HTTP reader component or have many limitations on render's side.
It is expected you may use this code base as a scratch for your modifications, which might be very application specific.

Regards,
Vladimir
0 Kudos
noemata
Beginner
625 Views
Hello all.

Sorry for delay.Just want to set the right level of expectations regarding IPP audio-video-codecs sample.

This sample is dedicated to demonstrate how one can get performance advantages on modern Intel architectures through Intel IPP usage in media codecs and hardware friendly codecs design. Itis not considered as a comprehensive media framework and this is the reason why we do not provide HTTP reader component or have many limitations on render's side.
It is expected you may use this code base as a scratch for your modifications, which might be very application specific.

Regards,
Vladimir

Perhaps you may have misread the problem outlined here. DX render fails under Vista! The changes made to simple_player were an attempt to resolve this problem and also make simple_player behave more like a conventional windows message loop driven application rather than a console application that renders to a console window (not the typical scenario for this sort of usage).

Re-integrating BLT render support was one way to fix the problem under Vista. The colorkey approach used by UMC appears to clash with Vista's DWM (display window manager), at least in the way the mechanism is presently employedby UMC code.

UMC does indeedprovide a good starting point for developers. We're just looking for guidance on how to make it work under Vista.
0 Kudos
Reply