Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

czar

Playing mpg or avi with delphiX

This topic is 6097 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I need to be able to play a avi or mpg on a delphix surface. So I thought to install sxmedia and problem would be solved. However, sxmedia will not compile for me.I get a number of [Error] SXMovie.pas(256): Incompatible types: ''DirectX.IDirectDrawSurface'' and ''DirectDraw.IDirectDrawSurface'' errors. Particulary in the following sxmovie unit procedure TSXMovie.SetupMediaSample; begin try FSample:=nil; FDDStream:=nil; FPrimaryVidStream:=nil; FMMStream.GetMediaStream(MSPID_PrimaryVideo, FPrimaryVidStream); FPrimaryVidStream.QueryInterface(IID_IDirectDrawMediaStream, FDDStream); FDDStream.CreateSample(nil,PRect(nil)^,0,FSample); FDXSurface := TDirectDrawSurface.Create(FDXDraw.DDraw); FSample.GetSurface(FSurface,FRect); FDXSurface.IDDSurface := FSurface; <====== this one except end; end; APart from trying to fix this code I was wondering if there were any other ways of displaying a movie on a delphix dxdraw surface? I am using windows 2000 with directx 8. I hope someone can help Ralph

Share this post


Link to post
Share on other sites
Advertisement
Solved my problem. SXmedia will work with the official delphiX only, and not the patched UnDelphiX. I switched back to the original unpatched delphiX and now it works sweet. The project I am working on seems to function as before, so no harm done.

Share this post


Link to post
Share on other sites
Hi Czar,
Dean Ellis, the SXMedia mogul will be back from his year long travel around the world in a few weeks, so he will probably update SXMedia to be compatible with UnDelphiX I would imagine.

L8R,


Dominique
http://www.DelphiGamer.com := for all your Object Pascal game development needs;

http://www.DelphiGamer.com := for all your Object Pascal game development needs;

Share this post


Link to post
Share on other sites
2 Czar: The problem you mentioned had easier (and better) solution: just try changing the order of DirectDraw, DXDraws and DirectX units in "uses" statement.


Edited by - Lifepower on February 3, 2002 9:51:22 AM

Share this post


Link to post
Share on other sites
Hi,

I also have a question to the SXMovie.
How can I set it to looped and how can I play it without the DoFlip Option set to true (It should play synchronic with the whle game...)

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!