summaryrefslogtreecommitdiff
path: root/ffplay.c
Commit message (Collapse)AuthorAge
* ffplay: remove manual bug option handling codeMarton Balint2014-10-17
| | | | | | It is supported as a codec option, and those are already parsed. Signed-off-by: Marton Balint <cus@passwd.hu>
* ffplay: remove delays when paused from video and subtitle threadMarton Balint2014-10-17
| | | | | | Once the frame queue is full, we will wait anyway. Signed-off-by: Marton Balint <cus@passwd.hu>
* Merge commit 'e58a140cf91d1a9cdfa3115d73c923dab0e9e7dc'Michael Niedermayer2014-10-17
|\ | | | | | | | | | | | | | | | | | | * commit 'e58a140cf91d1a9cdfa3115d73c923dab0e9e7dc': avplay: Always free opts Conflicts: ffplay.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit 'cf83c0173917a44b89a25ea2b435429bbf9ee767'Michael Niedermayer2014-10-17
|\| | | | | | | | | | | | | | | | | | | * commit 'cf83c0173917a44b89a25ea2b435429bbf9ee767': avplay: Always free find_stream_info options Conflicts: ffplay.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: dont leave swresampler in half initialized stateMarton Balint2014-10-09
| | | | | | | | | | | | | | | | | | | | On init failure, let's just free it, so next time it will be recreated from start. Also fixes Coverity CID 1241515. Reviewed-by: Michael Niedermayer <michaelni@gmx.at> Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: Separate AVFrame from AVSubtitleMichael Niedermayer2014-09-27
| | | | | | | | | | | | | | | | | | | | This is more robust and should avoid false positives in coverity That is if the type is ever mixed up, after this patch that would just be a null pointer dereference instead of a random possibly out of array access Reviewed-by: Marton Balint <cus@passwd.hu> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: use av_codec_get_pkt_timebase()Michael Niedermayer2014-09-24
| | | | | | | | | | | | Reviewed-by: Benoit Fouet <benoit.fouet@free.fr> Reviewed-by: Marton Balint <cus@passwd.hu> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: move pts calculating code to generic decoderMarton Balint2014-09-23
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: factorize decoder functions to generic decoderMarton Balint2014-09-23
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: handle fullscreen status on resize eventMarton Balint2014-09-23
| | | | | | | | | | | | | | | | | | | | In some cases resize events can happen even during fullscreen, so let's pass the proper flag to SDL_SetVideoMode. Fixes ticket #3964. Reported-by: Jeff Dwork <jeff@reggie.com> Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: try to fix build failure on appleMichael Niedermayer2014-09-17
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: use frame queue to determine last used posMarton Balint2014-09-16
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: factorize frame queue operationsMarton Balint2014-09-16
| | | | | | | | | | | | | | | | | | Create a generic frame and a frame queue struct to handle video picture queues and subtitle picture queues with common code. Also add the possibility to queue AVFrames, however at the moment we only use SDL_Overlay buffers for video and AVSubtitles for subtitles. Signed-off-by: Marton Balint <cus@passwd.hu>
* | Revert the default for ffplay to -noautoexit.Carl Eugen Hoyos2014-09-08
| | | | | | | | Reviewed-by: Marton Balint
* | ffplay: make autoexit the defaultMichael Niedermayer2014-09-06
| | | | | | | | | | See: f9bc65e399d1883da21ae03d07b09348a11a5f49 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: use av_malloc_array()Michael Niedermayer2014-08-26
| | | | | | | | | | Reviewed-by: Marton Balint <cus@passwd.hu> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Use new av_dict_set_int helper function.Reimar Döffinger2014-08-16
| | | | | | | | | | | | | | Get rid of the many, slightly differing, implementations of basically the same thing. Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
* | Drop remaining unneeded != NULLMichael Niedermayer2014-08-15
| | | | | | | | | | Reviewed-by: Clément Bœsch <u@pkh.me> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit 'f929ab0569ff31ed5a59b0b0adb7ce09df3fca39'Michael Niedermayer2014-08-15
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit 'f929ab0569ff31ed5a59b0b0adb7ce09df3fca39': cosmetics: Write NULL pointer equality checks more compactly Conflicts: cmdutils.c ffmpeg_opt.c ffplay.c libavcodec/dvbsub.c libavcodec/dvdsubdec.c libavcodec/dvdsubenc.c libavcodec/dxa.c libavcodec/libxvid_rc.c libavcodec/mpegvideo.c libavcodec/mpegvideo_enc.c libavcodec/rv10.c libavcodec/tiffenc.c libavcodec/utils.c libavcodec/vc1dec.c libavcodec/zmbv.c libavdevice/v4l2.c libavformat/matroskadec.c libavformat/movenc.c libavformat/sdp.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* | replace calls to url_feof() with avio_feof()James Almer2014-08-08
| | | | | | | | | | Signed-off-by: James Almer <jamrial@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: increase subtitle que sizeMichael Niedermayer2014-07-12
| | | | | | | | | | | | | | Fixes part of Ticket2516 with ffplay Reviewed-by: Marton Balint <cus@passwd.hu> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: decrease audio_diff_thresholdMarton Balint2014-06-24
| | | | | | | | | | | | | | | | Since audio clock calculations are more accurate now, it is safe to decrease the sync treshold to compensate the larger buffers caused by less frequent audio callbacks. Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: decrease max audio callbacks per secondMarton Balint2014-06-24
| | | | | | | | | | | | | | | | | | Too many audio callbacks per second can cause buffer underruns especially under load. As now we take into accound the elapsed time after an audio callback when determining current audio clock, it is not that important to use small buffer sizes and frequent audio callbacks, so lets remove the comment. Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: calculate SDL audio buffer size based on sample rateMarton Balint2014-06-24
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: pass simple integers to calculate_display_rect and ↵Marton Balint2014-06-24
| | | | | | | | | | | | | | | | set_default_window_size No change in functionality. Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: eliminate pictq_prev_pictureMarton Balint2014-06-24
| | | | | | | | | | | | | | | | | | | | | | Instead of directly rolling back the frame queue, keep the last displayed picture in the queue and use a boolean variable to keep track if it is displayed or not. This makes the code cleaner because it removes the complicated logic in pictq_prev_picture. There should be no change in functionality. Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: remove -ec handling codeMichael Niedermayer2014-06-17
| | | | | | | | | | | | Its handled by the generic option code Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: support rotated video.Clément Bœsch2014-05-23
| | | | | | | | | | | | | | with -f lavfi -i testsrc=s=hd1080 as source: rotate=90*PI/180 vs transpose=clock: 42fps -> 64fps rotate=180*PI/180 vs vflip,hflip: 75fps -> 77fps rotate=270*PI/180 vs transpose=cclock: 43fps -> 63fps
* | ffplay: Use av_gettime_relative()Olivier Langlois2014-05-17
| | | | | | | | | | | | | | | | | | | | Whenever av_gettime() is used to measure relative period of time, av_gettime_relative() is prefered as it guarantee monotonic time on supported platforms. Signed-off-by: Olivier Langlois <olivier@trillion01.com> Reviewed-by: Marton Balint <cus@passwd.hu> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: add support for toggling between multiple video filters with the w keyMarton Balint2014-05-17
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: try multiple sample rates if audio open failsMarton Balint2014-05-17
| | | | | | | | | | | | Should fix ticket #3509. Signed-off-by: Marton Balint <cus@passwd.hu>
* | cmdutils: replace usages of "#ifdef __MINGW32__" with "#ifdef _WIN32" ↵John Peebles2014-05-17
| | | | | | | | | | | | | | | | because MSVC only defines _WIN32 With the previous patch, this should fix ticket #3580 as well. Signed-off-by: John Peebles <johnpeeb@gmail.com>
* | ffplay: fix compilation with Visual StudioMarton Balint2014-05-17
| | | | | | | | | | | | | | | | Based on a patch by achristensen from trac.ffmpeg.org. Partially fixes ticket #3580. Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: increase AV_SYNC_THRESHOLD_MIN to 0.04Marton Balint2014-05-17
| | | | | | | | | | | | | | | | Less than 0.04 sec delays should not be noticable, and it helps us with 50fps content where some timing errors can cause a frame dup where it is not really necessary. Signed-off-by: Marton Balint <cus@passwd.hu>
* | avformat: add av_format_inject_global_side_data(), and disable it by defaultMichael Niedermayer2014-04-15
| | | | | | | | | | | | | | | | | | | | After this commit applications needs to call av_format_inject_global_side_data() or handle AVStream side data by some other means if they want it not to be lost. This fixes a API incompatibility with libav. libav API does not allow the data to be passed through AVPackets Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: display information on stream cyclingMichael Niedermayer2014-03-12
| | | | | | | | | | Reviewed-by: Marton Balint <cus@passwd.hu> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge commit 'b36bc81ccaa2fc85dc4bae7dc546c71e8833573d'Michael Niedermayer2014-02-10
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit 'b36bc81ccaa2fc85dc4bae7dc546c71e8833573d': avplay: add support for seeking to chapter marks Conflicts: doc/ffplay.texi ffplay.c ffplay uses pageup/down for seeking by +-10min thus this use of the keys conflicts. The merge thus uses them to seek to chapters when there are some or +-10min when there are not Merged-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: flush subtitle codecs as well with null packetsMarton Balint2014-02-05
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: reorder the filters to ensure that inputs of the custom filters are ↵Marton Balint2014-02-05
| | | | | | | | | | | | | | | | merged first For more info see http://ffmpeg.org/pipermail/ffmpeg-user/2013-December/018761.html Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: remove redundant prototypeLukasz Marek2014-01-27
| | | | | | | | | | Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: do not wait for the picture allocation to finish on exitMarton Balint2013-12-29
| | | | | | | | | | | | | | | | When SDL could not allocate a YUV overlay or open a window, the video thread got locked up because it waited for the allocation to finish forever. Reported-by: Carl Eugen Hoyos <cehoyos@ag.or.at> Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: remove two unneeded av_free_packet callsMarton Balint2013-12-29
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: remove some unneded av_frame_unref callsMarton Balint2013-12-29
| | | | | | | | | | | | av_buffersrc_add_frame implicitly unreferences the added frame. Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: remove unneeded avcodec_get_frame_defaultsMarton Balint2013-12-29
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: use precalculated frame size and bytes per sec valuesMarton Balint2013-12-29
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: precalculate audio output frame size and byte per secMarton Balint2013-12-29
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | Merge commit '84f131921ffb43d8070d5680e91f6a24d66ccac4'Michael Niedermayer2013-12-11
|\| | | | | | | | | | | | | | | | | | | * commit '84f131921ffb43d8070d5680e91f6a24d66ccac4': avplay: do not call avcodec_get_frame_defaults(). Conflicts: ffplay.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
* | ffplay: set default window size before starting audioMarton Balint2013-12-06
| | | | | | | | | | | | Fixes ticket #2381. Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: factor out function setting default window sizeMarton Balint2013-12-06
| | | | | | | | Signed-off-by: Marton Balint <cus@passwd.hu>
* | ffplay: remove no longer necessary codec flushMarton Balint2013-12-06
| | | | | | | | | | | | | | | | It was introduced in c2e8691c07ca52de7b6b00ba8f2b30c56fd786d7, but since we no longer no longer provide a custom get_buffer callback, the original cause of the issue is gone. Signed-off-by: Marton Balint <cus@passwd.hu>