Direct Show with Direct3d problem!!

Started by
2 comments, last by mrmrcoleman 19 years, 9 months ago
Hello. I have a program which renders from AVI files to Direct3D textures (as in the Texture3D9 sample in the SDK). These textures are used to animate sections of my interface, such as buttons being pressed etc. The animations were working fine apart from one problem. When the interface was first started the buttons were invisible because the animations obviously had not been started and so no data had been put into the textures. I tried several ways to get around this but eventually had to settle for loading a static image of the first frame of the animations into the texture on start-up using D3DXLoadTetureFromFileEx(). This works, and the textures are now visible when the interface is first started but now for some reason when the animation is started, four of the buttons are drawn rather than just the one, which is unnacceptable. Has anybody come across anything like this before? Does anybody have any suggestions as to what might be causing the problem, I don't really know where to start looking, perhaps it is a problem with the texture co-ordinates or something like that? Any help will be greatly appreciated as I am at my wits end now! Thanks in advance. Mark Coleman
Advertisement
sounds like a logic error to me. check the "Windowless Render" tutorial in DShow for a good implementation, sounds like your really close.
"Let Us Now Try Liberty"-- Frederick Bastiat
Dredd,

Thanks for the suggestion dude, but I am not using the VMR. Texture data is manually extracted and put into the texture bits?!

I mnay have to go over to VMR, but what a pain in the ass man!!

Thanks.

Mark Coleman
Hello all.

I just had thought, I am not telling the program how to apply the texture at any point I don't think. Should I be calling SetSamplerState at all before the drawing? It seems to me as if the texture is wrapping 4 times where there should be one? What settings do I need to prevent this??

Thanks in advance.

Mark Coleman

This topic is closed to new replies.

Advertisement