summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* demux_lavf: print seek failures in verbose modewm42015-03-241-6/+12
| | | | | Don't bother with making these visible by default, because often they are bogus and/or useless.
* audio: increase maximum amount of audio skipped for seekingwm42015-03-241-1/+1
| | | | | | | | | | | Precise seeking requires skipping audio, since the demuxer usually doesn't seek precisely enough. There is a sanity check that prevents skipping more than 300 seconds of audio. This still fails with very large mp3s. For example, with a 1GB sized mp3 with Xing headers, entries will be 4 MB apart on average, and occasionally much more. Just bump the limit. I'm not even sure why it was added in the first place; I suppose it's most important for files with real PTS resets.
* subprocess-win: clarify argument escaping logicJames Ross-Gowan2015-03-241-8/+8
| | | | This bit always seemed confusing to me.
* subprocess-win: handle empty arguments correctlyJames Ross-Gowan2015-03-241-0/+6
|
* vo_wayland: fix null dereferenceJari Vetoniemi2015-03-231-1/+1
| | | | | If compositor sends configure event before back_buffer is allocated, it will cause null dereference.
* vo_opengl: do not block on waylandJari Vetoniemi2015-03-235-0/+31
| | | | | | | | | When not receiving frame callbacks, we should not draw anything to avoid blocking the OpenGL renderer. We do this by extending gl context api, by introducing new optional function 'is_active', that indicates whether OpenGL renderers should draw or not. This fixes issue #249.
* vo_wayland: define opaque regionJari Vetoniemi2015-03-231-0/+9
| | | | | This allows compositor to optimize rendering, as it will know mpv is not transparent.
* vo_wayland: share frame callbacks.Jari Vetoniemi2015-03-234-39/+58
| | | | | | | | Define frame callback logic in wayland_common.c As this should be used by opengl renderer as well. Preferably drawing should be skipped entierly when no frame callbacks are received. However, for now only swap buffers is skipped.
* TOOLS: add a lua scripts for extracting and setting starttime with ytdlPatrick Hipp2015-03-231-0/+34
| | | | Signed-off-by: wm4 <wm4@nowhere>
* TOOLS: add a lua script for a -stay on top only during playback- modePatrick Hipp2015-03-231-0/+19
| | | | Signed-off-by: wm4 <wm4@nowhere>
* audio: prefer libdcadec by default if presentwm42015-03-231-1/+1
| | | | | If you enable this library in FFmpeg, you probably really want it to be used.
* mp_image: reject 0-sized imageswm42015-03-231-2/+1
| | | | | | Like FFmpeg/Libav do. It seems not all code can actually deal with this situation, so it's better to shift the special-cases to code which needs it (possibly OSD code; screenshots of 0x0 windows would just fail).
* vo_opengl: fix XYZ input gammaNiklas Haas2015-03-231-1/+1
| | | | | This seems to have been a mistranslation from the original code, which multiplied the gamma by 2.6 (*not* the color itself).
* demux_mkv_timeline: don't continue if reopening file failedwm42015-03-231-1/+1
| | | | | Could theoretically dereference "d" later in the loop. It's on an error codepath, so just give up.
* m_option: remove dead initializationwm42015-03-231-3/+3
|
* vo_vdpau: remove some minor code duplicationwm42015-03-231-13/+7
| | | | | The way-too-big API call for clearing the screen can be easily shared between two completely different codepaths.
* vo_vdpau: check vdpau API return valuewm42015-03-231-0/+1
|
* vdpau: remove dead assignmentwm42015-03-231-2/+1
| | | | | | I guess we don't really care whether this particular function succeeds. If it fails, it must be completely broken anyway and it would not matter much to us.
* client API: remove dead assignmentwm42015-03-231-1/+0
| | | | | Probably a leftover from an earlier refactoring. Now data is always in the format MPV_FORMAT_NODE.
* vo_opengl: remove dead assignmentwm42015-03-231-3/+3
|
* ta: memcpy(ptr, NULL, 0) is undefinedwm42015-03-231-1/+3
|
* m_property: memcpy(ptr, NULL, 0) is undefinedwm42015-03-231-1/+2
|
* video: use less technical language for PTS warningwm42015-03-231-1/+1
| | | | | | | "Non-monotonic" isn't even 100% correct; it's missing "strictly" (for briefness I guess), and also the message is printed if the PTS jumps forward. So just print something that is likely a bit easier to understand.
* encode: make --audio-channels=auto workwm42015-03-231-2/+4
| | | | Basically requested. Not that anyone cares.
* manpage: ipc: make requirements for newlines more explicitwm42015-03-231-0/+3
| | | | Clarifying because someone asked.
* video: fix update of vo-configured propertywm42015-03-231-0/+1
| | | | It obviously needs to be updated after the VO was destroyed.
* vo_opengl_cb: don't render OSD while VO is not createdwm42015-03-236-17/+26
| | | | | | | | | | | Unlike other VOs, this rendered OSD even while no VO was created (because the renderer lives as long as the API user wants). Change this, and refactor the code so that the OSD object is accessible only while the VO is created. (There is a short time where the OSD can still be accessed even after VO destruction - this is not a race condition, though it's inelegant and unfortunately unavoidable.)
* vo_opengl: move OSD rendering to separate functionwm42015-03-231-39/+41
| | | | | Also reindent the few lines that call into the actual renderer to remove the "draw_osd" goto.
* command: use mp_set_playlist_entrySai Ke WANG2015-03-221-3/+1
| | | | Signed-off-by: wm4 <wm4@nowhere>
* vo_opengl: fix video equalizer gamma controlswm42015-03-221-1/+4
| | | | It was ignored.
* af_bs2b: fix option default valuewm42015-03-221-1/+2
| | | | | | | | | --af=bs2b:help abort()ed because the default value of the "profile" option is not represented by any choice. Fix it by adding an "unset" choice. (It's a bit odd because there's already a "default" choice, which is not default, but I don't care enough about this filter.) Fixes #1712.
* vo_opengl: fix background color optionwm42015-03-211-7/+5
| | | | | | gl_video_set_options() didn't update it, so the default value set on initialization was used. Fix by always setting the clear color before the clear command; it's slightly easier to follow too.
* vo_opengl: fix bicubic_fast scalerwm42015-03-211-1/+1
|
* vd_lavc: less confusing message when hardware decoding won't workwm42015-03-201-2/+3
| | | | | | Codecs for hardware acceleration are not blacklisted, but whitelisted. Also, if this emssage is printed, the codec might not have any hardware acceleration support in the first place.
* demux_lavf: assume h264/hevc raw streams have no timestampswm42015-03-201-4/+12
| | | | | There are obscure methods to add timestamps to such streams, but assume they're unused.
* player: better handling of video with no timestampswm42015-03-204-11/+15
| | | | | | | | | | | Trying to handle such video is almost worthless, but it was requested by at least 2 users. If there are no timestamps, enable byte seeking by setting ts_resets_possible. Use the video FPS (wherever it comes from) and the audio samplerate for timing. The latter was already done by making the first packet emit DTS=0; remove this again and do it "properly" in a higher level.
* vo_xv: remove pointless castwm42015-03-201-2/+1
|
* vf_expand: fix memory leak on memory allocation failurewm42015-03-201-1/+3
| | | | Isn't it ironic.
* player: fix seekability testwm42015-03-201-1/+1
| | | | | Commit 39ed9b7d9 got this wrong, because these shitty flags are so goddamn confusing.
* mp_image: do not assume trailing stride padding existswm42015-03-201-4/+4
| | | | | | | | | | | | Normally, the size of an mage plane is assumed to be stride*height. But in theory, if stride is larger than width*bpp, the last line might not be padded, simply because it's not necessary. FFmpeg's or mpv's image allocators always guarantee that this padding exists (it wastes some insignificant memory for avoiding such subtle issues), but some other libraries might not. I suspect one such case might be Xv via vo_xv (see #1698), although my X server appears to provide full padding. In any case, it can't harm.
* video: uninline memcpy_pic functionswm42015-03-2016-93/+53
| | | | | | | | | There's literally no reason why these functions have to be inline (they might be performance critical, but then the function call overhead isn't going to matter at all). Uninline them and move them to mp_image.c. Drop the header file and fix all uses of it.
* video: replace pointless macrowm42015-03-202-9/+4
| | | | Some old absurdity.
* mp_image: remove unneeded thingswm42015-03-202-39/+16
| | | | (But I'd really prefer removing our own refcounting mechanism fully.)
* manpage: remove "experimental" notice from dxva2 codewm42015-03-192-2/+2
| | | | | | | It's relatively stable now. Also fix a typo in an unrelated place (better not waste commits on typos).
* stream_lavf: workaround broken rtmp "timeout" optionwm42015-03-191-4/+7
| | | | | | | | | | The libavformat rtmp protocol's "timeout" option has two problems: 1) Unlike all other protocols, it's in seconds and not microseconds 2) It enables "listen" mode, which breaks playback Make the --network-timeout do nothing in the rtmp case. Fixes #1704.
* player: warn against non-monotonic video PTS only oncewm42015-03-182-13/+9
| | | | | | | | For some reason there were two points in the code where it warned against non-monotonic video PTS. The one in video.c triggered on PTS going backwards or making large jumps forwards, while dec_video.c triggered on PTS going backwards or PTS not changing. Merge them into a single check, which warns against all cases.
* player: refuse to write resume file with unseekable fileswm42015-03-181-0/+6
| | | | | | | In fact this should happen on resume, not on saving, but it's simpler this way. Fixes #1701.
* osd: simplify an aspect of change detection handlingwm42015-03-1813-100/+74
| | | | | | | | | | | | | | | | | | There was a somewhat obscure optimization in the OSD and subtitle rendering path: if only the position of the sub-images changed, and not the actual image data, uploading of the image data could be skipped. In theory, this could speed up things like scrolling subtitles. But it turns out that even in the rare cases subtitles have such scrolls or axis-aligned movement, modern libass rarely signals this kind of change. Possibly this is because of sub-pixel handling and such, which break this. As such, it's a worthless optimization and just introduces additional complexity and subtle bugs (especially in cases libass does the opposite: incorrectly signaling a position change only, which happened before). Remove this optimization, and rename bitmap_pos_id to change_id.
* manpage: add a link to mpv.conf documentationwm42015-03-171-1/+1
| | | | Like we do it for input.conf and osc.conf.
* vd_lavc: change message about using hardware decodingwm42015-03-171-1/+1
| | | | This was requested. Apparently some find the old mesage confusing.
* af_lavfi: handle seekingwm42015-03-171-1/+27
| | | | | | | | To handle seeking correctly, we need to flush the filter. libavfilter does not support flushing, so we destroy and recreate it. We also need to handle resume-after-EOF, because the mpv audio code sends an EOF before and after seeking (the latter happens because the player drains the filter chain in a generic way, which "causes" EOF).
* DOCS: fix compilation instructions for MXE crosscompilationgunmantheh2015-03-171-0/+1
| | | | | | Add bootstrap step for Linux->Windows MXE crosscompilation. Signed-off-by: wm4 <wm4@nowhere>
* build: fix missing windows librariesKevin Mitchell2015-03-161-2/+2
|
* video: don't drop anamorphic scaling if it's too minorwm42015-03-161-8/+1
| | | | | | | | | This played e.g. a 1264x722 file as 1264x720. There was some code which dropped the aspect ratio if the video (in original resolution) wasn't scaled by more than 4 pixels. Commit 5f3c3f8c introduced this (although I'm not really sure what the code replaced by it did). Just remove this "feature".
* ao: slightly extend debug messageswm42015-03-161-1/+4
| | | | | This function already got uglified with debug printing; might as well go all the way.
* vo_opengl: reduce number of uniforms in dithering passwm42015-03-161-8/+5
| | | | | | | We now update uniforms every time, so we should try to reduce the number of uniforms to avoid performance penalties. (Originally, some caching was planned, but it looks like it would be too complicated to implement compared to the expected gains.)
* vo_opengl: move glViewport call closer to draw callwm42015-03-162-2/+3
|
* command: don't drop audio buffers when switching filterswm42015-03-161-1/+0
| | | | | | | This partially reverts commit ae7228c6. I guess the old behavior was slightly more popular. Fixes #1693 (probably).
* vo_opengl: fix srgb replacement optionsJames Ross-Gowan2015-03-161-1/+1
| | | | | | OPT_REPLACED can't specify option values or multiple options. Change to OPT_REMOVED. Also, target-prim doesn't have an srgb option. BT.709 uses sRGB primaries, so use it instead.
* vo_opengl: fix incorrectly drawn OSD in idle modewm42015-03-161-2/+2
| | | | | | Trade one bug for another, I don't even care anymore. Fixes #1691.
* vo_opengl: apply OSD color managementNiklas Haas2015-03-161-24/+39
|
* vo_opengl: improve queue size heuristicNiklas Haas2015-03-161-1/+1
| | | | | | | | The default scaling was a slight bit too low, which could cause buffer underruns in some cases. This should improve the result when using tscale filters other than oversample. The oversample case should be unaffected.
* vo_opengl: improve interpolation diagnosticsNiklas Haas2015-03-161-6/+9
| | | | | | This adds extra debugging output for buffer underruns, to help track down possible queueing issues. It also inverts the numberic output for tscale=oversample to make more sense, without changing the logic.
* vo_opengl: color manage after interpolationNiklas Haas2015-03-161-13/+18
| | | | | | | | | | | | This moves the color management code out of pass_render_main (which is now dedicated solely to up/downscaling and hence renamed pass_scale_main) and into a new function, which gets called from pass_draw_to_screen instead. This makes more sense from a logical standpoint, and also means that we interpolate in linear RGB, before color management - rather than after it, which is significantly better for color accuracy and probably also interpolation quality.
* man/vo: fix typoMartin Herkt2015-03-151-1/+1
|
* bootstrap: add waf mirrorMartin Herkt2015-03-151-5/+18
|
* filter_kernels: add comment to prevent confusionNiklas Haas2015-03-151-0/+2
| | | | There are conflicting definitons of Ginseng.
* vo_opengl: add oversample support for tscaleNiklas Haas2015-03-152-25/+54
| | | | | This is interesting mainly because it's essentially equivalent to the old smoothmotion algorithm. As such, it is now the default for tscale.
* vo_opengl: add oversample scalerNiklas Haas2015-03-152-0/+44
| | | | | | This is like nearest neighbour, but the edges between pixels are linearly interpolating if needed, as if they had been (naively) oversampled.
* vo_opengl: refactor smoothmotion -> interpolationNiklas Haas2015-03-155-130/+189
| | | | | | | | | | | | | This replaces the old smoothmotion code by a more flexible tscale option, which essentially allows any scaler to be used for interpolating frames. (The actual "smoothmotion" scaler which behaves identical to the old code does not currently exist, but it will be re-added in a later commit) The only odd thing is that larger filters require a larger queue size offset, which is currently set dynamically as it introduces some issues when pausing or framestepping. Filters with a lower radius are not affected as much, so this is identical to the old smoothmotion if the smoothmotion interpolator is used.
* vo_opengl: increase the number of video buffersNiklas Haas2015-03-151-12/+16
| | | | | | Also the size is now a simple #define that can easily be changed later. This is done for smoothmotion, which might want to blend more than 4 frames at once, depending on the setting.
* audio: fix off by one error in channel map selection codewm42015-03-151-2/+2
| | | | | | | The consequence was that some AOs (like ao_jack) could not output 8 channels. Fixes #1688.
* command: make "media-title" observablewm42015-03-151-1/+1
| | | | If metadata changes, its value could change.
* man: fix PDF buildMartin Herkt2015-03-151-3/+4
|
* vo_opengl: remove hwdec unmap_image callbackwm42015-03-145-22/+1
| | | | Not needed anymore; see previous commit.
* vo_opengl: silence vdpau hwdec warnings with smoothmotionwm42015-03-141-4/+10
| | | | | | | | | | | | | | | | Since the gl_rework merge, this started to print some OpenGL errors when using vdpau hardware decoding with vo_opengl smoothmotion. This happens because some hwdec unmap_image call were not paired with a map_image call. Unlike the old vo_opengl, the new code does not do this out of convenience (it would be a pain to track this exactly). It was triggered by smoothmotion, because not every rendered frame has actually a new input video frame (i.e. no map_image call, but it called unmap_image anyway). Solve this by handling unmappin