summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
| * define HAVE_COREAUDIO on platforms other than OSXwm42013-11-041-0/+1
| |
| * fix weird DPMS->EXT replacementwm42013-11-041-3/+3
| |
| * Merge branch 'master' into have_configurewm42013-11-0428-94/+478
| |\ | | | | | | | | | | | | Conflicts: configure
| * | configure: uniform the defines to #define HAVE_xxx (0|1)Stefano Pigozzi2013-11-0352-500/+528
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The configure followed 5 different convetions of defines because the next guy always wanted to introduce a new better way to uniform it[1]. For an hypothetic feature 'hurr' you could have had: * #define HAVE_HURR 1 / #undef HAVE_DURR * #define HAVE_HURR / #undef HAVE_DURR * #define CONFIG_HURR 1 / #undef CONFIG_DURR * #define HAVE_HURR 1 / #define HAVE_DURR 0 * #define CONFIG_HURR 1 / #define CONFIG_DURR 0 All is now uniform and uses: * #define HAVE_HURR 1 * #define HAVE_DURR 0 We like definining to 0 as opposed to `undef` bcause it can help spot typos and is very helpful when doing big reorganizations in the code. [1]: http://xkcd.com/927/ related
* | | vo_opengl: fix use of uninitialized memorywm42013-11-041-1/+1
| |/ |/| | | | | | | Pretty bad, although it should actually not cause any misbehavior. Comes from the hardware decoding interop commit.
* | Fix -Wshadow warning about seek function in playloop.cPaweł Forysiuk2013-11-041-11/+11
| | | | | | | | | | | | | | | | | | | | | | mpvcore/player/playloop.c: In function 'seek': mpvcore/player/playloop.c:209:54: warning: declaration of 'seek' shadows a global declaration [-Wshadow] mpvcore/player/playloop.c:209:12: warning: shadowed declaration is here [-Wshadow] mpvcore/player/playloop.c: In function 'queue_seek': mpvcore/player/playloop.c:360:25: warning: declaration of 'seek' shadows a global declaration [-Wshadow] mpvcore/player/playloop.c:209:12: warning: shadowed declaration is here [-Wshadow] Signed-off-by: wm4 <wm4@nowhere>
* | vo_opengl: add support for VA-API OpenGL interopwm42013-11-047-2/+160
| | | | | | | | | | | | | | | | VA-API's OpenGL/GLX interop is pretty bad and perhaps slow (renders a X11 pixmap into a FBO, and has to go over X11, probably involves one or more copies), and this code serves more as an example, rather than for serious use. On the other hand, this might be work much better than vo_vaapi, even if slightly slower.
* | vo_opengl: add infrastructure for hardware decoding OpenGL interopwm42013-11-049-32/+229
| | | | | | | | | | | | | | | | | | | | | | | | Most hardware decoding APIs provide some OpenGL interop. This allows using vo_opengl, without having to read the video data back from GPU. This requires adding a backend for each hardware decoding API. (Each backend is an entry in gl_hwdec_vaglx[].) The backends expose video data as a set of OpenGL textures. Add infrastructure to support this. The next commit will add support for VA-API.
* | mp_image: add helper for copying image attributeswm42013-11-032-0/+25
| | | | | | | | | | This enw function is similar to mp_image_set_params(), but doesn't force setting "hard" parameters like image size and format.
* | tools: add --no-cache --no-config to mpv_identify.shChrisK22013-11-031-1/+1
| |
* | player: fix quvi 0.9 playlist loadingwm42013-11-031-2/+3
| | | | | | | | The code made no sense at all.
* | demux: make determining seek capability genericwm42013-11-037-13/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Instead of having each demuxer do it (only demux_mkv actually did...), let generic code determine whether the file is seekable. This requires adding exceptions to demuxers where the stream is not seekable, but the demuxer is. Sort-of try to improve handling of unseekable files in the player. Exit early if the file is determined to be unseekable, instead of resetting all decoders and then performing a pointless seek. Add an exception to allow seeking if the file is not seekable, but the stream cache is enabled. Print a warning in this case, because seeking outside the cache (which we can't prevent since the demuxer is not aware of this problem) still messes everything up.
* | demux: remove movi_start/movi_end fieldswm42013-11-037-28/+13
| | | | | | | | | | | | | | Pointless, using stream->start_pos/end_pos instead. demux_mf was the only place where this was used specially, but we can rely on timestamps instead for this case.
* | stream: more consistent checks for whether stream is seekablewm42013-11-031-6/+10
| | | | | | | | | | | | | | | | | | Never check s->seek (except in init), because it'd have to check s->flags anyway. Also, for fast skippable streams (like pipes), don't set the bit that indicates support for seek forward. Make sure s->end_pos is always 0 for unseekable streams. Lots of code outside of stream.c uses this to check seeking support.
* | stream: reconnecting doesn't make sense if stream is not seekablewm42013-11-031-0/+2
|/ | | | | | | This stops mpv from being stuck in reconnecting at the end of the file with some unseekable streams. Test URL: http://playerservices.streamtheworld.com/pls/CBC_R1_VCR_H.pls
* w32: implement functionality required for window-scalewm42013-11-021-0/+23
| | | | Same semantics with respect to fullscreen as x11.
* x11: make window-scale use windowed size in fullscreen modewm42013-11-021-2/+2
| | | | | | This is a bit more intuitive, since before, the window size was just set to something random when setting the window-scale property during fullscreen.
* ta: re-add MinGW cargo cultingwm42013-11-021-0/+6
| | | | | | | | Not really cargo cult, but an unexplainable, needless difference that just exists to annoy us. Fixes that gcc on MinGW treats format specifiers in MSVC mode. Just why? Why?
* demux: rename Windows symbolswm42013-11-026-134/+110
| | | | | | | | | | | | | | | | | | | | There are some Microsoft Windows symbols which are traditionally used by the mplayer core, because it used to be convenient (avi was the big format, using binary windows decoders made sense...). So these symbols have the exact same definition as the Windows one, and if mplayer is compiled on Windows, the symbols from windows.h are used. This broke recently just because some files were shuffled around, and the symbols defined in ms_hdr.h collided with windows.h ones. Since we don't have windows binary decoders anymore, there's not the slightest reason our symbols should have the same names. Rename them to reduce the risk for collision, and to fix the recent regression. Drop WAVEFORMATEXTENSIBLE, because it's mostly unused. ao_dsound defines its own version if the windows headers don't define it, and ao_wasapi is not available on systems where this symbol is missing. Also reindent ms_hdr.h.
* demux_mkv: fix warningwm42013-11-021-1/+1
| | | | | | | | Now that matroska.pl generates struct fields in deterministic order, this should be the last time I change this. (gcc and clang shouldn't warn about this line of code, but since they do, we want to workaround and silence the warning anyway.)
* matroska.pl: Sort the generated struct field listDiogo Franco (Kovensky)2013-11-021-2/+2
| | | | | | | Newer versions of perl randomize the hash used for hashes every time it's run; this makes the order of the fields be non-deterministic. Tack a sort there to make it deterministic. Needed to fix (or allow fixing) a buggy gcc warning.
* Fix some more -Wshadow warningswm42013-11-0110-36/+36
| | | | | | These aren't printed with newer gcc or clang versions for some reason. All of them seem to be about local variables shadowing global functions.
* tl_matroska: initialize segment related arrays with 0wm42013-11-011-4/+6
| | | | | | | | | | | | | mpv crashed when linked files were not found. The reason was that the chapters array contained some uninitialized data. I have no idea how this code works (after the merge). The old code actually seems to remove missing chapters, while the new code just leaves them unintiialized. Work around the crash by initializing the chapters array (and a bunch of other things) with 0, which means the missing chapter will be located at 00:00:00 and have no name. There is a regression since commit af0306d.
* video: check profiles with hardware decodingwm42013-11-018-72/+142
| | | | | | | | | | | | | | | We had some code for checking profiles earlier, which was removed in commits 2508f38 and adfb71b. These commits mentioned that (working) hw decoding was sometimes prevented due to profile checking, but I can't find the samples anymore that showed this behavior. Also, I changed my opinion, and I think checking the profiles is something that should be done for better fallback to software decoding behavior. The checks roughly follow VLC's vdpau profile checks, although we do not check codec levels. (VLC's profile checks aren't necessarily completely correct, but they're a welcome help anyway.) Add a --vd-lavc-check-hw-profile option, which skips the profile check.
* demux_mkv: use a more universal zero initializerwm42013-11-011-1/+1
| | | | | | | | | | | | Unfortunately, we can't avoid this warning 100%, because ebml_info is written by a Perl script. I think the script writes the struct fields in random order (thanks Perl), so there's no way to know whether the first struct field is a scalar or a struct. At least {0} is always valid here, even if it shows a warning. (The compilers are wrong, see e.g. [1].) [1] http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53119
* Enable -Wshadowwm42013-11-017-17/+16
| | | | | | | | | This one really did bite me hard (see previous commit), so enable it by default. Fix some cases of shadowing throughout the codebase. None of these change behavior, and all of these were correct code, and just tripped up the warning.
* options: fix positional suboption asrgumentswm42013-11-011-2/+2
| | | | | | | | | E.g. "-vf scale=848:480" set the w argument twice, instead of setting w and then h. This was caused by accidental shadowing of a local variable. Regression since probably 4cd143e.
* input: show deprecation warnings for some recently replaced commandswm42013-11-011-4/+4
| | | | Let's see if I get annoyed reactions...
* command: replace speed_mult with multiply commandwm42013-10-315-17/+5
| | | | The compatibility layer still takes care of the old speed_mult command.
* command: add generic "multiply" commandwm42013-10-316-0/+85
| | | | Essentially works like "add".
* command: add property to scale window sizewm42013-10-314-0/+51
|
* x11: factor out normal window resize codewm42013-10-311-23/+31
| | | | | | | | As preparation for resizing the window with input commands in the following commit. Since there are already so many functions which somehow resize the window, add the word "highlevel" to the name of this new function.
* sd_lavc: display DVD subs with unknown durationwm42013-10-311-0/+6
| | | | | | | | | | | | | | | | | | DVD subs (rarely) have subtitle events without end timestamp. The duration is unknown, and they should be displayed until they're replaced by the next event. FFmpeg fails hard to make us aware whether duration is unknown or actually 0, so we can't distinguish between these two cases. It fails at this twice: AVPacket.duration is set to 0 if duration is unknown, and AVSubtitle.end_display_time has the same issue. Add a hack that considers all bitmap subtitles with duration==0 as events with uknown length. I'd rather accidentally display a hidden subtitle (if they exist at all), instead of not displaying random subtitles at all. See github issue #325.
* ao_pulse: fix channel layoutswm42013-10-311-1/+4
| | | | | | | | The code was selecting PA_CHANNEL_POSITION_MONO for MP_SPEAKER_ID_FC, which is correct only with the "mono" channel layout, but not anything else. Remove the mono entry, and handle mono separately. See github issue #326.
* vd_lavc: add more ifdeffery and ffmpeg cargo culting for correctnesswm42013-10-311-7/+13
| | | | | | | | | | | | | We mixed the "old" AVFrame management functions (avcodec_alloc_frame, avcodec_free_frame) with reference counting. This doesn't work correctly; you must use av_frame_alloc and av_frame_free. Of course ffmpeg doesn't warn us about the bad usage, but will just mess up things silently. (Thanks a lot...) While the alloc function seems to be 100% compatible, the free function will do bad things, such as freeing memory that might still be referenced by another frame. I didn't experience any actual bugs, but maybe that was pure luck.
* dec_video: remove unused declaration of a former global variablewm42013-10-311-2/+0
|
* encoding-example-configs: add more comments regarding the scaling methodRudolf Polzer2013-10-311-2/+16
|
* gl_common: osx: fix compilation with latest XQuartz RCStefano Pigozzi2013-10-301-1/+1
| | | | Looks the gl.h header in XQuartz is incompatible with the one in OS X 10.9.
* tech-overview.txt: reflect recent updateswm42013-10-301-21/+32
| | | | mplayer.c split, and some other things.
* ta: track location debug info in 2 more caseswm42013-10-301-0/+2
| | | | Was overlooked.
* x11: restore support for --wid=0wm42013-10-301-2/+4
| | | | | | | | | | This stopped working when the code was changed to create a window even if --wid is used. It appears we can't create our own window in this case, because in X11 there is no difference between a window with the root window as parent, and a window that is managed by the WM. So make this (kind of worthless) special case use the root window itself.
* x11: remove ancient metacity hackwm42013-10-301-14/+1
| | | | | Tested with recent metacity; this code is not triggered anymore. The code was added in 2003 and probably has been unused for years.
* x11: minor cosmeticswm42013-10-301-16/+11
|
* main: improve a terminal messagewm42013-10-301-1/+1
| | | | Better prefer real English...
* player: merge mp_osd.h into mp_core.hwm42013-10-307-59/+33
| | | | | | | | Just doing this because mp_osd.h and osd.c is not consistent. There are some other header files (command.h and screenshot.h), but since I don't feel too good about inflating mp_core.h, I'm not merging them, at least not yet.
* mp_core: sort function prototypes by source filewm42013-10-301-58/+68
| | | | | | | I considered making a header file for each .c file, but decided against it. Asking around, not making separate headers was deemed acceptable. In the end, all of these depend on MPContext and store state inside of it, so separate headers aren't all that useful anyway.
* ao_alsa: return negative value on error in play()wm42013-10-301-3/+3
| | | | | No functional change, because the only user of ao_play() ignores return values below 1.
* Fix style of the HP Slate 7 vf-add line.Rudolf Polzer2013-10-301-1/+1
|
* encoding-example-profiles: support HP Slate 7's weird aspect.Rudolf Polzer2013-10-301-5/+37
| | | | Also, replace broken noup= by lavfi expressions.
* Split mplayer.cwm42013-10-3017-5084/+5400
| | | | | | | | | | | | | | | | | | | | mplayer.c was a bit too big. Split it into multiple files. I hope the way it's split makes sense. Maybe some things don't make too much sense, or go against intuition. These will fixed as soon as I notice them. Some files are a bit questionable (misc.c, osd.c, configfiles.c), and suggestions how to organize this better are welcome. Regressions are possible due to reorganized include statements. Obviously I didn't just copy mplayer.c's orgy of include statements, but recreated them for each file. It's easily possible that there are oversights and mistakes, which will show up on other platforms. There is one actual change: the public avutil.h include is removed from encode.h, and I tried to replace most FFMIN/FFMAX/av_clip uses. I consider using libavutil too much as dangerous, because the set of include files they recursively pull in is rather arbitrary and is different between FFmpeg and Libav.
* Move files part of the playback core to player sub-directorywm42013-10-3018-50/+48
| | | | | | | | All these files access mp_core.h and MPContext, and form the actual player application. They should be all in one place, and separate from the other sources that are mere utility helpers. Preparation for splitting mplayer.c into multiple smaller parts.
* gl_x11: change error message when GL3 context creation failswm42013-10-281-1/+1
| | | | | | | | | | | | | | On systems that provide legacy OpenGL (up to 2.1), but not GL3 and later, creating a GL3 context will fail. We then revert to legacy GL. Apparently the error message printed when the GL3 context creation fails is confusing. We could just silence it, but there's still a X error ("X11 error: GLXBadFBConfig"), which would be quite hard to filter out. For one, it would require messing with the X11 error handler, which doesn't even carry a context pointer (for application private data), so we don't even want to touch it. Instead, change the error message to inform the user what's actually happening: a fallback to an older version of OpenGL.
* getch2: assume EOF when input file descriptor is invalidwm42013-10-281-2/+5
| | | | | | | | | | | | | When starting mpv with nohup, file descriptor 0 seems to be invalid for some reason. (I'm not quite sure why it should be... /proc/pid/fd/0 seems to indicate it's just /dev/null, and using /dev/null explicitly shows that it works just fine.) select() will always immediately return, and this causes mpv to burn CPU without reason. Fix this by treating it as EOF when read() returns EBADF. Also add EINVAL to this condition, because it seems like a good idea.
* getch2: move global state to file scope variableswm42013-10-281-6/+5
| | | | | Using static variables for mutable state inside functions is a bad idea, because it's not immediately obvious that it is what it is.
* mplayer: handle subtitle renderer cleanup via uninit_playerwm42013-10-282-10/+24
| | | | | | | | | This might actually fix an issue with DVB channel switching, because that uses some sort of hack to reinitialize the demuxer, which causes the subtitle renderer to initialize twice. As consequence, the assert in add_subtitle_fonts_from_sources() would trigger. I didn't actually test the DVB case, because I don't have the hardware.
* x11_common: refactor of fstype codewm42013-10-281-102/+73
| | | | This is completely pointless, but it still somehow bugged me.
* cocoa: apply the more invasive constraining only with cmd+1/2/3Stefano Pigozzi2013-10-281-2/+10
| | | | | Regression from bc49957 Fixes #321
* command: disable autorepeat for some commands (actually properties)wm42013-10-283-5/+29
| | | | | | | | | | | | Disable autorepeat for the "add"/"cycle" commands when changing properties that are choices (such as fullscreen, pause, and more). In these cases, autorepeat is not very useful, and can rather harmful effects (like triggering too many repeated commands if command execution is slow). (Actually, the commands are just dropped _after_ being repeated, since input.c itself does not know enough about the commands to decide whether or not they should be repeated.)
* x11: fix border togglingwm42013-10-272-2/+5
| | | |