Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: sfeMovie (video & audio playback library with many codecs)  (Read 151828 times)

0 Members and 1 Guest are viewing this topic.

Ceylo

  • Hero Member
  • *****
  • Posts: 2325
    • View Profile
    • http://sfemovie.yalir.org/
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #210 on: January 01, 2016, 04:36:04 pm »
You're not supposed to run build_ffmpeg.sh, just usual CMake + Visual Studio build, see Getting Started page.

Building from Visual Studio will use your MSYS2 installation (and its bash) when appropriate, so you would not need to bother the build_ffmpeg.sh or msys2_shell.bat. About diffutils and pkg-config, they can help FFmpeg configuration but I don't think they are required.

Note that if you only used build_ffmpeg.sh, you only have FFmpeg binaries right now, but no sfeMovie binary.
Want to play movies in your SFML application? Check out sfeMovie!

sfUser

  • Newbie
  • *
  • Posts: 12
    • View Profile
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #211 on: January 01, 2016, 09:23:16 pm »
Yes, but after building ffmpeg, i opened the generated solution and compiled sfeMovie + the sample project.
In fact, I already added openFromStream to sfeMovie and its working OK.
I'll refactor the code a bit and post it here for your consideration.

sfUser

  • Newbie
  • *
  • Posts: 12
    • View Profile
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #212 on: January 02, 2016, 01:58:46 am »
Here are the modified files (in comparison to the current git trunk) to be able to open using SFML's InputStream class.

I've tested on windows (vs2015).
Note: some files have the line endings converted to windows (were originally linux).

It is based on this SO post:
https://stackoverflow.com/questions/19785254/play-a-video-from-memorystream-using-ffmpeg

It doesn't appear to have memory leaks. The program I tested read a movie from a zip file using SFML's physFS class available in the SFML's wiki.

Feel free to incorporate this into sfeMovie, if you wish to, or modify the code to better reflect your coding conventions.

NOTE2: there is a warning converting from sf::Int64 to int in the read function (just remembered now).

Ceylo

  • Hero Member
  • *****
  • Posts: 2325
    • View Profile
    • http://sfemovie.yalir.org/
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #213 on: January 02, 2016, 04:04:26 pm »
Thank you, going to look at it to get it integrated in the official release :)
Want to play movies in your SFML application? Check out sfeMovie!

Ceylo

  • Hero Member
  • *****
  • Posts: 2325
    • View Profile
    • http://sfemovie.yalir.org/
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #214 on: January 02, 2016, 04:17:31 pm »
I am pleased to announce support for textual (srt, ass/ssa, ...) subtitles in addition to the already existing support for bitmap subtitles :)
See here for more details.
Thank you feliwir for your contribution!
Want to play movies in your SFML application? Check out sfeMovie!

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11046
    • View Profile
    • development blog
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #215 on: April 22, 2016, 04:05:44 pm »
Looks like the Air Conflicts: Pasific Carriers removed his stuff. The video you embedded on the site doesn't exist anymore and the linked domain only leads to a domain seller. ;)

And I noticed a little typo in the download section: "Although ony Visual Studio 2015 binary"

How is it looking with MinGW support? Or can I use the VS libraries?
« Last Edit: April 22, 2016, 04:17:17 pm by eXpl0it3r »
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

Ceylo

  • Hero Member
  • *****
  • Posts: 2325
    • View Profile
    • http://sfemovie.yalir.org/
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #216 on: April 25, 2016, 07:58:03 pm »
Hi,

I've fixed the website, thanks for your comments :)
As for MinGW it is not officially supported, although you can probably get things working if you tweak the build system a little bit. I don't officially support it anymore because with all the MinGW variants it was requiring more time than what I wanted to spend on it. So indeed I recommend using VS215.
Want to play movies in your SFML application? Check out sfeMovie!

JohnSon123

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #217 on: January 25, 2017, 07:21:40 pm »
Tell me how to connect it http://sfemovie.yalir.org/1.0/
to my project in visual studio 2015.
Error appears when you start:
"Could not find any video decoder for this video format"
Or is there any exception, and the program crash.

UroboroStudio

  • Newbie
  • *
  • Posts: 25
    • View Profile
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #218 on: February 15, 2017, 08:20:42 pm »
The lastest download links for sfeMovie doesn't work with SFML 2.4.2

I build my own binaries for Visual Studio 2013 32bits and working with SFML 2.4.2

Here is the download link if anyone needed:

https://mega.nz/#!KMcUQK7Y!PMqnZEfMybQckIs8QAMxroQIjjDCJ7YWMVxjPtblEtw

Thanks Ceylo for the library  :)

Gerard Wensink

  • Newbie
  • *
  • Posts: 5
    • View Profile
    • Github
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #219 on: May 11, 2018, 05:12:29 pm »
For me the function getCurrentImage() doesn't work either.
What i do to get it into a sprite is a in between draw.

void updatemovie() {
    if (live_movie->getStatus()!=sfe::Stopped) {
        live_movie->update();
        texture_from_movie->draw(*live_movie);
        texture_from_movie->display();

//        texture_from_movie_new=live_movie->getCurrentImage();
        texture_from_movie_new=texture_from_movie->getTexture();
        sf::Texture::bind(&texture_from_movie_new);
        sprite_from_movie.setTexture(texture_from_movie_new,false);
//        sprite_from_movie.setTexture(live_movie->getCurrentImage(),false);
    }
}

(live_movie is pointer to a sfe::movie)

Ceylo

  • Hero Member
  • *****
  • Posts: 2325
    • View Profile
    • http://sfemovie.yalir.org/
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #220 on: May 12, 2018, 07:55:58 pm »
Why do you want it to be in a sprite?
Want to play movies in your SFML application? Check out sfeMovie!

gamepopper

  • Newbie
  • *
  • Posts: 35
    • View Profile
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #221 on: June 14, 2018, 11:49:43 pm »
Hello,

Dumb question probably, but I'm trying a bunch of videos with the sfeMovieDemo and for most of them the lib cannot find the audio decoder.

I've tried MKV (cannot find mp3), MP4 (cannot find aac) and MPG (cannot find ac3). The only format that works for audio is uncompressed AVI (where the video stream doesn't work but the audio stream works fine).

I'm building from the source using Visual Studio C++ 2017 for Windows.


eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11046
    • View Profile
    • development blog
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #222 on: June 15, 2018, 08:11:50 am »
What binaries did you use or how did you build it?

According to the FAQ there are two different versions: http://sfemovie.yalir.org/latest/faq.php#supported-codecs
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

gamepopper

  • Newbie
  • *
  • Posts: 35
    • View Profile
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #223 on: June 16, 2018, 12:02:18 am »
What binaries did you use or how did you build it?

According to the FAQ there are two different versions: http://sfemovie.yalir.org/latest/faq.php#supported-codecs

I'm not sure how I can tell what binaries I have, I cloned what was on GitHub and built the entire project with CMake and MSYS2 Mini-GW 64-bit. The codec object folder (FFmpeg-objects/libavcodec) seems to show the full list of codecs in that FAQ. have I've missed a step or there are completely different setup instructions for Visual Studio?

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11046
    • View Profile
    • development blog
    • Email
Re: sfeMovie (video & audio playback library with many codecs)
« Reply #224 on: June 16, 2018, 12:16:01 am »
Did you pick the wanted codecs when building with CMake as stated in the Getting Started page?

http://sfemovie.yalir.org/latest/start.php
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

 

anything