Jump to content
  • Advertisement
Sign in to follow this  
Aiwendil

Video Files

This topic is 3253 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

Hi everyone, How do you play video files using Win32/DirectX? I know that there is the video for windows API, but every example I've found doesn't even compile so I'm having a hard time learning it. Do you know of any good examples/tutorials that work? Are there any other ways to play a video (preferably .avi files, but others work if necessary)? These would be cutscenes and intro movies for my game. I've also looked at the Playing AVI files with DirectX article here on gamedev.net, but that code didn't compile either. Thanks

Share this post


Link to post
Share on other sites
Advertisement
Yes, that's the article.

These are the errors and warnings (some I can fix, others I can't):

1>------ Build started: Project: avi312, Configuration: Debug Win32 ------
1>Compiling...
1>AboutBox.cpp
1> WINVER not defined. Defaulting to 0x0600 (Windows Vista)
1>avisurface.cpp
1> WINVER not defined. Defaulting to 0x0600 (Windows Vista)
1>c:\...\avisurface\videoexample\avisurface.cpp(18) : error C2664: 'AVIStreamOpenFromFileW' : cannot convert parameter 2 from 'char *' to 'LPCWSTR'
1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
1>c:\...\avisurface\videoexample\avisurface.cpp(24) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\avisurface.cpp(30) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\avisurface.cpp(77) : warning C4244: '=' : conversion from 'DWORD' to 'WORD', possible loss of data
1>c:\...\avisurface\videoexample\avisurface.cpp(255) : error C2664: 'AVIStreamOpenFromFileW' : cannot convert parameter 2 from 'char *' to 'LPCWSTR'
1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
1>c:\...\avisurface\videoexample\avisurface.cpp(262) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\avisurface.cpp(267) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\avisurface.cpp(283) : error C2664: 'IDirectSoundBuffer::Lock' : cannot convert parameter 3 from 'BYTE **' to 'LPVOID *'
1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
1>dderrmsg.cpp
1> WINVER not defined. Defaulting to 0x0600 (Windows Vista)
1>c:\...\avisurface\videoexample\dderrmsg.cpp(14) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(16) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(18) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(20) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(22) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(24) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(26) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(28) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(30) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(32) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(34) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(36) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(38) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(40) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(42) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(44) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(46) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(48) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(50) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(52) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(54) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(56) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(58) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(60) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(62) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(64) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(66) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(68) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(70) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(72) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(74) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(76) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(78) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(80) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(82) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(84) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(86) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(88) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(90) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(92) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(94) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(96) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(98) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(100) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(102) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(104) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(106) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(108) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(110) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(112) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(114) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(116) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(118) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(120) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(122) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(124) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(126) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(128) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(130) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(132) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(134) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(136) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(138) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(140) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(142) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(144) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(146) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(148) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(150) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(152) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(154) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(156) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(158) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(160) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(162) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(164) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(166) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(168) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(170) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(172) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(174) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(176) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(178) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(180) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(182) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(184) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(186) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(188) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(190) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(192) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(194) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(274) : warning C4996: 'strcpy': This function or variable may be unsafe. Consider using strcpy_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\string.h(74) : see declaration of 'strcpy'
1>c:\...\avisurface\videoexample\dderrmsg.cpp(276) : warning C4996: 'sprintf': This function or variable may be unsafe. Consider using sprintf_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNINGS. See online help for details.
1> c:\program files (x86)\microsoft visual studio 9.0\vc\include\stdio.h(366) : see declaration of 'sprintf'
1>DDFramw.cpp
1> WINVER not defined. Defaulting to 0x0600 (Windows Vista)
1>c:\...\avisurface\videoexample\ddframw.cpp(103) : error C2664: 'CWnd::MessageBoxW' : cannot convert parameter 1 from 'const char [28]' to 'LPCTSTR'
1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
1>c:\...\avisurface\videoexample\ddframw.cpp(112) : error C2061: syntax error : identifier 'exception'
1>c:\...\avisurface\videoexample\ddframw.cpp(112) : error C2310: catch handlers must specify one type
1>c:\...\avisurface\videoexample\ddframw.cpp(117) : error C2065: 'x' : undeclared identifier
1>c:\...\avisurface\videoexample\ddframw.cpp(117) : error C2228: left of '.what' must have class/struct/union
1> type is ''unknown-type''
1>c:\...\avisurface\videoexample\ddframw.cpp(120) : error C2317: 'try' block starting on line '106' has no catch handlers
1>c:\...\avisurface\videoexample\ddframw.cpp(127) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\ddframw.cpp(129) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\ddframw.cpp(139) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\ddframw.cpp(145) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\ddframw.cpp(157) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\ddframw.cpp(165) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\ddframw.cpp(171) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\ddframw.cpp(174) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\ddframw.cpp(177) : error C3861: 'exception': identifier not found
1>c:\...\avisurface\videoexample\ddframw.cpp(228) : error C2664: 'CFileDialog::CFileDialog(BOOL,LPCTSTR,LPCTSTR,DWORD,LPCTSTR,CWnd *,DWORD,BOOL)' : cannot convert parameter 2 from 'const char [6]' to 'LPCTSTR'
1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
1>c:\...\avisurface\videoexample\ddframw.cpp(232) : error C2440: 'initializing' : cannot convert from 'wchar_t *' to 'LPSTR'
1> Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast
1>c:\...\avisurface\videoexample\ddframw.cpp(242) : error C2061: syntax error : identifier 'exception'
1>c:\...\avisurface\videoexample\ddframw.cpp(242) : error C2310: catch handlers must specify one type
1>c:\...\avisurface\videoexample\ddframw.cpp(248) : error C2061: syntax error : identifier 'exception'
1>c:\...\avisurface\videoexample\ddframw.cpp(248) : error C2310: catch handlers must specify one type
1>c:\...\avisurface\videoexample\ddframw.cpp(250) : error C2065: 'x' : undeclared identifier
1>c:\...\avisurface\videoexample\ddframw.cpp(250) : error C2228: left of '.what' must have class/struct/union
1> type is ''unknown-type''
1>c:\...\avisurface\videoexample\ddframw.cpp(253) : error C2317: 'try' block starting on line '245' has no catch handlers
1>c:\...\avisurface\videoexample\ddframw.cpp(256) : error C2317: 'try' block starting on line '239' has no catch handlers
1>StdAfx.cpp
1> WINVER not defined. Defaulting to 0x0600 (Windows Vista)
1>videoexample.cpp
1> WINVER not defined. Defaulting to 0x0600 (Windows Vista)
1>c:\...\avisurface\videoexample\videoexample.cpp(96) : error C2061: syntax error : identifier 'exception'
1>c:\...\avisurface\videoexample\videoexample.cpp(96) : error C2310: catch handlers must specify one type
1>c:\...\avisurface\videoexample\videoexample.cpp(100) : error C2065: 'x' : undeclared identifier
1>c:\...\avisurface\videoexample\videoexample.cpp(100) : error C2228: left of '.what' must have class/struct/union
1> type is ''unknown-type''
1>c:\...\avisurface\videoexample\videoexample.cpp(103) : error C2317: 'try' block starting on line '93' has no catch handlers
1>videoexampleDlg.cpp
1> WINVER not defined. Defaulting to 0x0600 (Windows Vista)
1>Generating Code...
1>Build log was saved at "file://c:\Users\...\Documents\Visual Studio 2008\Projects\avi312\avi312\Debug\BuildLog.htm"
1>avi312 - 37 error(s), 94 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========





Also, when I tried to use the already compiled application included with the program (before I tried compiling the code), a message box appeared saying "AVI Init Failed" on most of the avi files I tried and on the ones that did work, the picture never showed up and the audio was messed up.

It also uses DirectDraw, which I thought was no longer supported and very outdated.

Share this post


Link to post
Share on other sites
Your project's character set is configured as Unicode. The code you entered is not Unicode. Either convert your code to use Unicode or convert the project's character set to Multi-Byte. The quickest solution would be to change the project settings. You are probably using the 2008 version of your compiler in which case go to Project->Properties->General and look around until you find the right setting. However at some point you should really consider switching to Unicode.

edit: That will probably fix some of the errors but not necessarily all. Also that article is literally over 10 years old. Was that the best one you could find? You might try the cutscene sample mentioned here as part of DirectShow. The sample page here also mentions a Texture3D9 Sample that Draws video on a Microsoft DirectX 9.0 texture surface. This would allow you to embed video directly into your game. Like on a computer monitor or something.

Share this post


Link to post
Share on other sites
Thanks, that fixed a few of the errors. Unfortuantely, those were mostly the errors I knew how to fix.

This isn't my code, it's the code from the tutorial. I'm not copying it for use in my projects, I'm just trying to learn from it. Since it doesn't work, I figured it would probably be better to ask here on gamedev about playing video files.

Share this post


Link to post
Share on other sites
Yeah, that article is pretty old, actually.

You can try one of the many DirectShow samples (look for "Playback" in the "Area" column). If you have specific problems with them, come back with details error messages and stuff and we'll see what we can do to help.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • 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!