Yalir / sfeMovie

sfeMovie is a simple C++ library that lets you play movies in SFML based applications. It relies on FFmpeg to read medias and remains consistent with SFML's naming conventions.
http://sfemovie.yalir.org/
GNU Lesser General Public License v2.1
114 stars 37 forks source link

How to connect "sfe movie" #102

Closed NePutin94 closed 7 years ago

NePutin94 commented 7 years ago

Tell me how to connect it http://sfemovie.yalir.org/1.0/ to my project. Error appears when you start: "Could not find any video decoder for this video format" Or is there any exception, and the program crash. zz0k1lojr7m

Ceylo commented 7 years ago

Hello JohnSoz,

Version 1.0 of sfeMovie is outdated. See http://sfemovie.yalir.org/latest/ for the latest version.

As for the error you get, it just means the decoders you need are not in the binary of sfeMovie you're using. See http://sfemovie.yalir.org/latest/faq.php#supported-codecs You probably need to download a binary with all the decoders or build sfeMovie yourself.

NePutin94 commented 7 years ago

I could not build sfe movie And so the use of "sfeMovie-1.0-windows-vs2012.zip", connecting the include and lib to the project. I will try to use a newer version.I just have to throw dll in the files with the project?

25 янв. 2017 г. 21:31 пользователь "Ceylo" notifications@github.com написал:

Hello JohnSoz,

Version 1.0 of sfeMovie is outdated. See http://sfemovie.yalir.org/latest/ for the latest version.

As for the error you get, it just means the decoders you need are not in the binary of sfeMovie you're using. See http://sfemovie.yalir.org/ latest/faq.php#supported-codecs You probably need to download a binary with all the decoders or build sfeMovie yourself.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Yalir/sfeMovie/issues/102#issuecomment-275191939, or mute the thread https://github.com/notifications/unsubscribe-auth/AYLListyOiigGvDjQelPMdLmoP_TQnB3ks5rV5TjgaJpZM4Ltrer .

Ceylo commented 7 years ago

Yes sfeMovie works like any other library. See "Using sfeMovie" section in http://sfemovie.yalir.org/latest/start.php for more details.

NePutin94 commented 7 years ago

Errors are now no. Video is also no :-). Here is the code: Movie movie; movie.openFromFile("video.webm"); window.setFramerateLimit(60); window.setVerticalSyncEnabled(true);

movie.fit(0, 0,100,100); movie.play();

while (window.isOpen()) {

window.clear(); window.draw(movie); window.display(); } All I'm doing is correct?

feliwir commented 7 years ago

Do you get any errors in your stdout? If this codec is not suported there should be a message. Apart from that your code looks correct, yes. But you need to make sure your codec is supported by your sfeMovie binary

NePutin94 commented 7 years ago

My code was not correct! I did so, and there was a white screen for a few seconds and then there was an error in the console. while (window.isOpen()) { move.play(); move.update(); window.clear(); window.draw(move); window.display(); } image

How to fix this error?

Ceylo commented 7 years ago

play() should not be in the loop

Ceylo commented 7 years ago

Apart from that if you are interested you can find a working example here: https://github.com/Yalir/sfeMovie/blob/master/examples/MinimalistDemo/main.cpp

NePutin94 commented 7 years ago

Thank you very much for the prompt assistance! Now everything is working!