[Libav-user] yet another ffplay reassembling

邵鄭叡 vampirictutor at gmail.com
Mon May 23 12:24:48 EEST 2022


Hi every buddy,
I just created a repo at  https://github.com/grizzlybears/ffplay_vc


Here is partial of the front page, you can get what it does, hope you
will enjoy it :)
///////////////////////////////////////////////////////////////////////////////////////////

ffplay_vc
Get your own video player in 30 minutes :)

Sometimes, we hope we can embed an 'AV player' into our own
application. It would have API like this:

	int  Open(const char* fileName) ;	// open media file
	void Close(void) ;                  //close media
	int  Play(HWND  screen) ;
	int  Stop() ;

Or, we may want a 'AV Decoder' to play some customized stream from
spec protocol/device (i.e. NVR), like this

	int   open_stream(const AVCodecParameters * codec_para);  // spec which codec
	void  close_all_stream();  // close all codec
	void  feed_pkt(AVPacket* pkt ); // feed a 'pkt' to the decoder

	void  video_refresh(); // called from timer to refresh display

When in those moments, 'ffplay' would be a good start, em... until we
see the code :) Yes 'ffplay' is a comprehensive sample of ffmpeg, it
doesn't intend to be reusable.
We need a 'clean' ffplay providing above API, and yes here it is.


More information about the Libav-user mailing list