summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* stream_cdda: various fixesreimar2012-04-011-10/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix cdda speed default value, range and use more robust condition. Based on patch by Ingo Brückl [ib wupperonline de]. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34458 b3059339-0415-0410-9bf9-f77b7e298cf2 Do not call paranoia_overlapset with 0, it actually causes cdparanoia to just hang. Instead use it to set/unset PARANOIA_MODE_OVERLAP. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34459 b3059339-0415-0410-9bf9-f77b7e298cf2 Fail if trying to seek beyond the last chapter, not just if it is beyond the end of the disc. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34460 b3059339-0415-0410-9bf9-f77b7e298cf2 cdda: set position to an actual EOF position when we set EOF. This avoids some inconsistency like the stream indicating EOF but a read still returning more data. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34462 b3059339-0415-0410-9bf9-f77b7e298cf2 Allow PARANOIA_MODE_FULL with skipping. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34467 b3059339-0415-0410-9bf9-f77b7e298cf2 Don't call paranoia_modeset() for PARANOIA_MODE_DISABLE. cdparanoia destroys start sector information after such a call. Since it is pointless without setting a mode anyway, don't do it. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34468 b3059339-0415-0410-9bf9-f77b7e298cf2 Add comment to a condition that is just a hack around a cdparanoia bug. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34472 b3059339-0415-0410-9bf9-f77b7e298cf2 Add checks for errors in stream_cdda's get_track_by_sector(). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34495 b3059339-0415-0410-9bf9-f77b7e298cf2 Fix seeking beyond EOF in stream_cdda to work with cache. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34577 b3059339-0415-0410-9bf9-f77b7e298cf2
* Merge remote-tracking branch 'origin/master'wm42012-04-0138-2554/+1270
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: bstr.c bstr.h etc/input.conf input/input.c input/input.h libao2/ao_pulse.c libmpcodecs/vf_ass.c libmpcodecs/vf_vo.c libvo/gl_common.c libvo/x11_common.c mixer.c mixer.h mplayer.c
| * stream_vstream: fix vstream_error format stringUoti Urpala2012-04-011-2/+3
| | | | | | | | | | Code printing a variable already-formatted string passed it to mp_msg as the format string argument. Use "%s" instead.
| * ao_pulse: add hacks to work around seek problemsUoti Urpala2012-03-261-1/+19
| | | | | | | | | | | | | | | | pa_stream_flush() seems to work pretty badly in general. The visible symptoms included at least old audio continuing for a significant time after the call, and bogus latency reporting causing temporary video freezes after a seek. Add some hacks to work around these problems. The result seems to work most of the time on my machine at least...
| * ao_pulse, core: make pulse thread wake up core for more dataUoti Urpala2012-03-266-13/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For ao_pulse, the current latency is not a good indicator of how soon the AO requires new data to avoid underflow. Add an internal pipe that can be used to wake up the input loop from select(), and make the pulseaudio main loop (which runs in a separate thread) use this mechanism when pulse requests more data. The wakeup signal currently contains no information about the reason for the wakup, but audio buffers are always filled when the event loop wakes up. Also, request a latency of 1 second from the Pulseaudio server. The default is normally significantly higher. We don't need low latency, while higher latency helps prevent underflows reduces need for wakeups.
| * ao_pulse: convert to new AO APIUoti Urpala2012-03-261-222/+282
| |
| * cocoa_common: update screen info before entering fullscreenStefano Pigozzi2012-03-251-0/+1
| | | | | | | | | | | | If the user moved the window to another screen, fullscreen mode would still use the original screen. Fix to use the screen the window is currently on (unless overridden by --xineramascreen).
| * input.c: simplify command definitionsUoti Urpala2012-03-252-145/+152
| | | | | | | | | | Change command definitions to allow writing the command definition table in more readable format.
| * macosx_finder_args: use a custom logfile instead of system.logStefano Pigozzi2012-03-251-0/+12
| | | | | | | | | | | | | | | | | | | | Change the macosx_finder_args function so that when mplayer2 is invoked from the Finder in a Mac application bundle, it redirects the output to ~/Library/Logs/mplayer2.log instead of cluttering the global system.log. This doesn't affect terminal use which keeps writing to stdout and stderr.
| * VO: move gl+cocoa before corevideo in default VO orderStefano Pigozzi2012-03-251-1/+4
| | | | | | | | | | | | | | | | | | The gl video output is faster and has more features than corevideo, so it should be preferred on mac osx. This doesn't affect GUI compatibility because they specify the corevideo video output along with the suboptions for the shared buffer name to mmap in.
| * configure: disable X11 opengl backend if Cocoa is enabledStefano Pigozzi2012-03-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | The recommended way to get function pointers to the functions in the OpenGL library is through dlopen/dlsym/dlclose. This causes problems in the Cocoa OpenGL backend when -lGL (X11's OpenGL headers) is linked to the binary together with -framework OpenGL. The linked OpenGL symbols are always from -lGL, causing all the function pointers to point to null when getFunctions is called against a Cocoa OpenGL context. For this reason change the configure autodetection code to disable the vo_gl X11 backend when cocoa is active.
| * cocoa_common: add license informationStefano Pigozzi2012-03-252-0/+38
| |
| * vo_quartz: remove this video outputStefano Pigozzi2012-03-254-1398/+0
| | | | | | | | | | | | | | | | | | This video output is not useful anymore. It is based on Carbon to draw the mplayer window and this has been deprecated by Apple in 10.5. The upcoming 10.8 OSX release should deprecate most of Carbon, so it doesn't make sense to keep vo_quartz in the codebase when there are modern and better alternatives (vo_gl and vo_corevideo).
| * macosx_finder_args: use cocoa instead of carbonStefano Pigozzi2012-03-255-136/+90
| | | | | | | | | | | | | | | | | | | | | | | | macosx_finder_args was using Carbon and wasn't usable any longer on modern versions of MacOSX. This is very useful to embed mplayer in a mac application bundle. When using application bundles, the operating system will call the main function with only one argument that identifies the process serial number (this is some additional process identifier in osx other than the pid). File open events are then dispatched to the application through events that must be handled accordingly.
| * cocoa_common: fix double click handlingStefano Pigozzi2012-03-251-8/+8
| | | | | | | | | | | | | | The Cocoa framework generates only a NS*MouseDown event when handling the second click of a double click (no NS*MouseUp). If that's the case put mouse up key in mplayer2's fifo when dealing with the MouseDown Cocoa event.
| * cocoa_common: accept window drag event from the whole window surfaceStefano Pigozzi2012-03-251-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | Change the window to accept mouse drag events not only on the title bar, but also on the rest of the window surface; this includes the video area. It looks like the changing of the window mask resets the behaviour specified in the delegate method, probably due to some strange interaction with NSBorderlessWindow. For this reason call -setPresentationOptions in the -fullscreen method to remind cocoa the behaviour we want.
| * options, x11+cocoa: add option --cursor-autohide-delayStefano Pigozzi2012-03-256-16/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add option --cursor-autohide-delay to control the number of milliseconds with no user interaction before the mouse cursor is hidden. There are two negative values with useful special meanings: * A value of -1 prevents the cursor from hiding (useful for users with multiple displays). * A value of -2 prevents the cursor from showing upon activity. The default is 1 second to keep the behaviour consistent with the past X11 backend implementation. Remove the vo_mouse_autohide field as it was always true.
| * etc/input.conf: make file contents match default key bindingswm42012-03-251-100/+146
| | | | | | | | | | | | | | | | | | There were some slight differences between what input.conf mapped, and what was in input.c def_cmd_binds[]. Make them match. Add some minor documentation improvements in input.cfg. Also remove double comments ('##'), because they were confusing.
| * x11: remove wskeys.hwm42012-03-252-107/+20
| | | | | | | | | | Use the <X11/keysym.h> xlib header instead. I'm not sure why mplayer defined these constants itself.
| * x11: input: add print and menu keyswm42012-03-253-0/+3
| |
| * x11: add KP_Separator to key mappingwm42012-03-252-0/+2
| | | | | | | | | | | | | | | | | | | | | | At least on some keyboards, the key between '0' and 'Enter' on the key pad is mapped to KP_Separator. Since X11 VOs accept unicode input, the mplayer keycode this key generates depended on the numlock state, and with numlock enabled this mapped to an ASCII character. This is probably not what the user wanted, since two physical keys will always map to the same key code. Map it to KP_DEC.
| * x11: allow unicode inputwm42012-03-252-29/+49
| | | | | | | | | | | | | | | | | | This change allows using non-ASCII keys with X11. These keys were ingored before. Technically, this creates an invisible, non-interactive input method context. If creation fails, the code falls back to the old method, which allows a subset of ASCII only.
| * input: handle UTF-8 terminal inputwm42012-03-251-0/+11
| | | | | | | | | | | | | | | | | | | | | | This assumes the terminal uses UTF-8. If invalid UTF-8 is encountered (for example because the terminal uses a legacy encoding), the code falls back to the old method and feeds each byte as key code to the input code. In theory, UTF-8 input could randomly fail, because the code in getch2.c doesn't try to fill the input buffer correctly with input sequences longer than a byte. This is a problem with the design of the existing code.
| * input: allow unicode keys and reassign internal key codeswm42012-03-257-27/+103
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This moves all key codes above the highest valid unicode code point (which is 0x10FFFF). All key codes below MP_KEY_BASE now directly map to unicode (KEY_ENTER is 13, carriage return). Configuration files (input.conf) can contain unicode characters in UTF-8 to map non-ASCII characters/keys. This shouldn't change anything user visible, except that "direct key codes" (as used in input.conf) will change their meaning. Parts of the bstr functions taken from libavutil's GET_UTF8 and slightly modified.
| * x11: fix setting UTF-8 window titles for some special caseswm42012-03-251-29/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Setting the WM_NAME/WM_ICON_NAME window properties didn't always work: apparently there are some characters that can't be represented in the X STRING or COMPOUND_TEXT encodings, such as U+2013 EN DASH. The function Xutf8TextListToTextProperty partially converts the string, and returns a value different from 'Success'. This means vo_x11_set_property_string didn't set these window properties. On most modern window managers, this is not a problem, since these use the _NET_WM_NAME/_NET_ICON_NAME and the UTF8_STRING encoding. Some older WMs like IceWM don't read these, and the window title remains blank. It's not clear what exactly we should do in this situation, but fix it by setting set the WM_NAME/WM_ICON_NAME properties as UTF8_TEXT. This violates the ICCCM, but at least IceWM seems to handle this well. See also: http://lists.freedesktop.org/archives/xorg/2004-September/003391.html http://lists.freedesktop.org/archives/xorg/2004-September/003395.html
| * vo_gl: cocoa: add support for --ontopStefano Pigozzi2012-03-253-4/+33
| | | | | | | | | | Make the cocoa backend change the non-fullscreen window level according to the value of the ontop property.
| * timeline: subs: keep subtitle tracks in source timeUoti Urpala2012-03-255-34/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Timeline handling converted the pts values from demuxed subtitles to timeline scale. Change the code to do most subtitle handling in original subtitle source pts, and instead convert current playback timeline pts to those units when deciding which subtitle to show. The main functionality changes are that now demuxed subtitles which overlap chapter boundaries are handled correctly (at least for libass subtitles), and external subtitles are assumed to use same pts scale as current source (this needs improvements later). Before, a video subtitle that had a duration continuing past the end of the chapter would continue to be shown for the original duration, even if the chapter ended and playback switched to a position in the source where the subtitle shouldn't exist. Now, the subtitle will correctly end. Before, external subtitle files were interpreted as specifying pts values in timeline scale. Now, they're interpreted as specifying pts values in source file time scale, for _every_ source file. This is probably more likely to be what the user wants for the "main" source file in case there is one, but almost certainly not quite right for multiple source files where the same subs could be shown over different scenes. If the user wants them to match some main source file, it's probably still better to have incorrect extra subs for video from some files than to have every subtitle appearing at the wrong time. The new code makes it easier to change the interpretation of the subtitle times, and some configurability should be added in the future.
| * vo_xv: remove direct rendering supportUoti Urpala2012-03-251-111/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Direct rendering support in vo_xv (used with --dr) had at least two problems. First, OSD drawing modified the buffers; this meant that if the buffers were used for reference frames there would be video corruption. I don't think "performance optimization" with this level of drawbacks is appropriate with today's machines any more. Direct rendering could still be used for non-reference frames, but there's a second problem: with direct rendering enabled the same buffer is used for every frame, and with the XShm extension that is used by default there's no checking that the previous frame has been completely uploaded to the graphics card before it's overwritten by the next one. This could be fixed, but as Xv is becoming obsolete I don't see it as a priority to improve it. Thus I'm simply removing the parts of functionality that were more likely to break things than improve playback.
| * cosmetics: vf_vo.c: reformatUoti Urpala2012-03-251-102/+107
| |
| * cosmetics: misc minor cleanupsUoti Urpala2012-03-257-17/+6
| | | | | | | | | | The deleted ZRM* things were only relevant to vo_zr, which was deleted earlier.
| * core: improve sub and audio start after timeline part switchUoti Urpala2012-03-201-15/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When switching to a timeline part from another file, decoders were reinitialized after doing the demuxer-level seek. This is necessary for audio because some decoders read from the demuxer stream during initialization and the previous stream position before seek could have been at EOF. However, this initialization sequence could lose first subtitles or first part of audio. The problem for subtitles was that the seek itself or audio initialization could already have buffered subtitle packets from the new position, and the way subtitles are reinitialized flushes packet buffers. Thus early subtitles could be lost (even if they were demuxed - unfortunately demuxers may not know about still active subtitles earlier in the file, but that's another issue). Fix this by moving subtitle and video reinitialization before the demuxer seek; they don't have the problems which prevent that for audio. Audio initialization can already decode and buffer some output. However, the seek_reset() call done last would then throw away this buffered output. Work around this by adding an extra flag to seek_reset().
| * options: move mixer.h options to structUoti Urpala2012-03-208-24/+30
| |
| * mixer: reindent/cosmetic changeswm42012-03-202-106/+103
| | | | | | | | | | | | There should be no real semantic changes. Remove the mixer_setbothvolume macro, as it was unused.
| * core: restructure main play loop, continue audio after videoUoti Urpala2012-03-192-283/+247
| | | | | | | | | | | | | | | | | | | | | | Restructure parts of the code in the main play loop. The main functionality difference is that if a video track ends first, now audio will continue to be played until it ends too. Now the process also wakes up less often if there's no need to update video or audio. This will reduce unnecessary wakeups especially when paused, but may make handling of input events laggier when fd-based notifications are not supported (like most input on Windows).
| * terminal output: if audio/video pts is missing, show "???"Uoti Urpala2012-03-161-13/+26
| | | | | | | | | | | | Change the terminal status line to show "???" instead of a huge negative number if audio or video pts is missing (there was a partial workaround for audio before, but not video or A-V difference).
* | gl_common: minor cleanup/refactorwm42012-03-312-64/+44
| | | | | | | | | | | | | | | | | | Remove all platform/GUI specific includes from gl_common.h. Get rid of the ugly union in MPGLContext. Use function pointers instead of an ifdef ridden switch statement in uninit_mpglcontext(). Always include glext.h, not only on Windows. None of this should actually change any functionality.
* | gl_common: remove unused glValName()wm42012-03-312-58/+0
| | | | | | | | Using helper programs like apitrace is better for debugging.
* | gl_common: move header hacks into gl_header_fixes.hwm42012-03-312-208/+232
| | | | | | | | | | Keep this horrible (but unfortunately necessary) kludge out of the main code.
* | libvo: add vo_gl3wm42012-03-3110-1/+3112
| | | | | | | | | | | | | | | | | | This new vo is heavily based on vo_gl.c. It provides better scale filters, dithering, and optional color management with LittleCMS2. It requires OpenGL 3. Many features are enabled by default, so it will be slower than vo_gl. However, it can be tuned to behave almost as vo_gl.
* | gl_common: cocoa: add OpenGL 3.2 context creation codeStefano Pigozzi2012-03-313-10/+53
| | | | | | | | | | Add a new option to the cocoa window creation code in order to decide which OpenGL context to create.
* | gl_common: slightly change win32 GL 3 context creationwm42012-03-312-18/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | |