summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* commands: add pt_clear command to clear playlistwm42012-02-103-0/+29
| | | | | | | | | This deletes all playlist elements, except the currently active playlist entry. NOTE: this doesn't remove parent nodes in the case when we really have a play tree (as opposed to a play list). Apparently this doesn't cause any harm.
* bstr: add bstr_eatstart()wm42012-02-092-0/+11
|
* vo_gl: add "backend" suboption to allow selecting the GUI backendwm42012-02-094-35/+54
| | | | | | | | | | | | The "backend" suboption allows selecting the GUI backend used by vo_gl. Normally, it's auto-selected, but sometimes it's desireable to explicitly select it. Remove the gl_sdl VO. This can now be done by using: --vo=gl:backend=sdl This is based on svn commit 34438, and tries to be compatible with it. The undocumented numeric backend names serve this purpose. (They are undocumented because names are preferred.)
* vo_gl: minor cleanupsreimar2012-02-093-22/+20
| | | | | | | | | | | | | | | | | | Fix spelling. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34006 b3059339-0415-0410-9bf9-f77b7e298cf2 Fix disabled code. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34007 b3059339-0415-0410-9bf9-f77b7e298cf2 Remove pointless pointer indirection for shader program strings. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34016 b3059339-0415-0410-9bf9-f77b7e298cf2 Remove usage of glColor3f, there is not really a point in it. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34149 b3059339-0415-0410-9bf9-f77b7e298cf2
* vo_gl: add noise filterreimar2012-02-094-13/+84
| | | | | | | | | | Add disabled feature: noise filter for vo_gl. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34014 b3059339-0415-0410-9bf9-f77b7e298cf2 Hook up -vo gl noise support. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@34015 b3059339-0415-0410-9bf9-f77b7e298cf2
* core: add option to start in paused statewm42012-02-093-0/+7
| | | | | | | | | | | | The --paused option will start the player in paused state. That means it will start out with a still image of the first frame. This can be useful in combination with --ss to inspect a certain frame. Caveat: this plays a small bit of audio at the start, which might be perceived as an annoying artifact. This is because this is implemented by frame stepping after initialization in order to decode and display the first video frame.
* i lost my brainwm42012-01-261-1/+1
| | | | should be squashed with "screenshot: improve quality by using additional swscale flags"
* input.c: simplify command definitionswm42012-01-262-129/+130
| | | | | | | | | | | | | | | | Using type = -1 for terminating the command argument list was an unnecessary complication. Change it to 0 to make use of default initialization. Remove the explicit termination from the command definitions. Now the argument list is automatically terminated by C default initialization rules. Also remove other redundant {0} initializers. When an argument's default value is actually initialized to something other than 0, make the field being initialized explicit (e.g. {1} becomes {.i = 1}). Try to make use of whitespace more consistent.
* x11: fix setting UTF-8 window titles for some special caseswm42012-01-251-9/+15
| | | | | | | | | | | | | | | | | | | | | | | 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 Also fix a minor memory leak when conversion to COMPOUND_TEXT fails.
* screenshot: add png compression settingwm42012-01-184-1/+4
| | | | | | | | The default compression setting is 7, which is hopefully a good balance between speed of compression, and resulting file sizes. The maximum png compression will be very slow even on fast computers. On the other hand, the lowest compression setting produces files of several MB size with normal video resolutions, which should be avoided as well.
* screenshot: add jpg supportwm42012-01-184-12/+122
| | | | | | The screenshot image file type can now be selected with the --screenshot-filetype option. The --screenshot-jpeg-quality option controls the compression setting of the written JPEG image file.
* osd: add setting to display OSD always on terminalwm42012-01-184-12/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Now the option --term-osd=force will cause mplayer to display all OSD messages on the terminal, even if there is video. Possible values for --term-osd: - auto: use video OSD, or of there's no video, the terminal (default) - off: always use video for OSD - force: always use terminal for OSD -term-osd and --term-osd are equivalent to --term-osd=force. This changes the meaning of the option, since -term-osd used to enable the OSD default behavior, i.e. --term-osd=auto. -noterm-osd has the same effect as --term-osd=off, and is kept for compatibility. Implementation note: The location for the OSD text was shared between the two code paths (it was in osd_state.osd_text). We can't rely on the fact that the video-OSD update code normally isn't run when --term-osd is called. When e.g. panscan is updated, the video OSD code will draw the OSD anyway. This would sometimes show unwanted OSD text on the video. Deal with this by putting the current terminal-OSD text in a different place (in MPContext.terminal_osd_text) to deal with this.
* options: allow choice options without parameterwm42012-01-182-8/+20
| | | | | | | | | | | If an m_option_type_choice option is declared with M_OPT_IMPLICIT_DEFAULT in its flags, it doesn't require a parameter. For example, if --opt is such an option, it can be invoked as "--opt=val", "-opt", or "--opt". The last two will set the option to the first choice the option declares. Note that "-opt val" (using the old option syntax) is not allowed in this case, as it would be ambiguous. Normal option parsing should be unaffected.
* core: add new support for reading .cue fileswm42012-01-187-0/+497
| | | | | | | | | | | | | | | | | | | | | | | | | | | Playing a .cue file directly will now parse the .cue file, and load and play the file(s) referenced in the cue. If multiple files are referenced, a timeline including all files will be created to create the impression of a single, flat audio file containing all the tracks. For each track, a chapter is created. The chapter navigation commands can be used to jump between tracks. The chapter titles will use the string provided by the track's TITLE cue command. (The -identify command can be used to print all chapters in a not so user friendly way.) Other than the chapter names, there is no attempt at displaying or exposing any other meta data contained in the cue files yet. The handling (or lack of thereof) of gaps (track pregaps and postgaps) is probably not correct yet. In general, mplayer's mapping of tracks to the source audio files can be verified by examining the timeline, which will be printed when passing the -v switch. Note that this has nothing to do with the old cue:// support. The old code isn't touched, and is still only able to play .cue/.bin pairs. Prefixing a .cue file with cue:// will always invoke the old code, while playing a .cue file directly (i.e. "mplayer file.cue") will always use the new code. Playing audio images (.cue/.bin pairs of files) doesn't work yet.
* bstr: add some utility functionswm42012-01-182-0/+58
| | | | | | | | bstr_strip_ext and bstr_get_ext were taken from find_subfiles.c. bstr_cut is extended to work like bstr_splice: passing a negative argument will start counting from the end of the string, e.g. bstr_cut("abc", -2) == "bc"
* Merge branch 'gradfun' into my_masterwm42012-01-181-9/+47
|\
| * vf_gradfun: change default parameterswm42012-01-101-2/+2
| |
| * vf_gradfun: add size parameter, which sets radius according to movie diagonalwm42012-01-101-2/+23
| | | | | | | | | | | | | | | | | | | | | | | | This patch adds a "size" parameter, which scales the filter radius according to movie diagonal, the unit being percent of diagonal. This makes the effect far more predictable across movies of different resolutions. Usage example (with possibly useless values): -vf gradfun=strength=1.2:size=2.3 Based on a patch by Radosław Szkodziński <astralstorm@gmail.com>
| * vf_gradfun: use option parserwm42012-01-101-9/+26
| |
* | Merge branch 'eosd' into my_masterwm42012-01-187-346/+504
|\ \
| * | vo_gl: use generic eosd codewm42011-12-253-145/+124
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is an experiment. The change probably doesn't matter much. One issue with the old code was that "large" images caused each sub-image to be created and rendered as a new texture. "Large" in this case means larger than 32x32 pixels, which actually isn't very large with screen sizes beyond 1500x1000 pixels. This means rendering a simple subtitle for a fullscreened video may allocate many small textures, one for each glyph. On the other hand, the old code could be fixed by tuning the texture sizes for "modern" work loads. Also, the new code uses less deprecated OpenGL features and draws all sub-images in one batch. There are two possible issues the new code could cause: - Drivers could have performance issues with the larger texture sizes and the number of glTexSubImage2D calls on it - There is only one EOSD texture, which could become full (it's enlarged on demand, but restricted by driver texture size limitations) It has been reported that this is faster on OSX with ATI GPUs than the old code.
| * | libvo, vo_vdpau: make the EOSD packer code from vo_vdpau genericwm42011-12-254-201/+380
| |/ | | | | | | | | | | | | The code in eosd_packer.c/.h is taken from vo_vdpau.c and has been made independent from vdpau API specifics. This allows other VOs, which need to pack the small EOSD images into a large surface for efficiency, to use this code.
* | Merge branch 'softvol' into my_masterwm42012-01-1815-211/+413
|\ \
| * | ao_coreaudio: fix partial volume controlwm42012-01-181-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If digital pass-through is used, this supported setting the volume (just mute, actually), but not getting the volume. This will probably lead to a stuck mute state in the mplayer frontend. Make the code respond to volume queries even if digital pass-through is used. Ideally, ao_coreaudio should implement full mute control, but I can't even test on OSX.
| * | ao_pulse: add mute controlwm42012-01-181-18/+37
| | |
| * | ao_alsa: add mute controlwm42012-01-181-23/+43
| | |
| * | ao_alsa: use "Master" mixer channel instead of "PCM" by defaultwm42012-01-181-1/+1
| | | | | | | | | | | | | | | | | | | | | Do this, because the "Master" channel normally provides proper mute control. The old default can be forced with: --mixer-channel=PCM
| * | mixer, libao: add proper mute controlwm42012-01-183-23/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The mixer frontend code can now make use of a proper system mixer mute toggle, if the audio output driver supports it. The consequence is that, if support is available, mplayer will no longer temporarily set the system volume to 0 if mute is enabled. Generally, the code now deals with the following combinations of available AO features: - software volume control forced by user (--softvol / soft_vol flag) => if enabled, never touch the "hardware" controls - "hardware"/driver volume control available (whether AOCONTROL_GET/SET_VOLUME works) => if not available, enable volume controls by enabling softvol - "hardware"/driver mute control (AOCONTROL_GET/SET_MUTE) => if not available, emulate by setting volume to 0 - whether the volume+mute controls are kept or not when the AO is closed (indicated by ao->no_persistent_volume) => if not persistent, restore the volume/mute next time the AO is opened
| * | libao2: try to identify some audio outputs that have persistent volumewm42012-01-185-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The mplayer frontend (specifically, mixer.c) needs to know this. If the audio output doesn't remember the volume across reinitialization, the frontend will restore the volume settings. There is also the assumption that the volume setting isn't global in this case (i.e. changing it won't change the volume of other applications or annoy the user otherwise). None of these changes have been tested. I'm guessing that ESD and NAS do per-connection non-persistent volume settings.
| * | af: fix crash when trying to use volume controls with AC3 pass-throughwm42012-01-181-1/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changing the volume when softvol is enabled or if the audio output driver doesn't support volume controls causes insertion of the "volume" filter. This fails with AC3. Since the filter wasn't removed after that, and the filter chain was in a bogus state, random crashes occured past this point. Fix it by reinitializing the filter chain completely on failure. Volume controls simply won't work. (This can't be fixed, because AC3 is a compressed format, and would require additional decoding/encoding passes in order to support arbitrary volume changes.) This also affects balance controls.
| * | core: remove EDL mutingwm42012-01-183-44/+1
| | | | | | | | | | | | | | | | | | I'm not sure what's the point of this feature. Aside from that, the EDL code is relatively buggy anyway, and I see no reason why such an obscure feature should be left in, if it possibly causes bugs.
| * | audio: reset mplayer's mute state when the system mixer volume changeswm42012-01-183-9/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before this commit, the mute state was only reset when either mute was explicitly cleared, or the volume was changed via mplayer controls. If the volume controls are connected to the system mixer, and the system mixer volume is changed otherwise (e.g. with alsamixer), the mute setting was inconsistent. Avoid this by checking the volume. If the returned volume is not 0, the mute flag is considered invalid. This relies on system mixers always returning a volume of 0 when mplayer has set the volume 0. Possible caveat: if the audio output's volume control don't return a volume of exactly 0 after 0 was written, enabling mute basically won't work. It will set the volume to silence, forget the previous volume, and report that mute is disabled.
| * | audio: pretend muting doesn't set volume to 0wm42012-01-181-18/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Muting audio is implemented by setting the volume controls to 0. This has the annoying consequence that attempting to change the volume while the audio is muted will reset the user's volume setting. E.g. increasing the volume while muted will start from 0, instead from the volume that was set before muting. Changing the volume while muted effectively resets the volume to 0 (which is not very useful), with no possibility of restoring the old voume. This commit makes mplayer always report the volume that was set when mute was enabled while mute is still active. Caveat: this might be have confusing effects when the volume control is directly connected with a system wide mixer setting. Now it's even less obvious (and thus more confusing) that muting will set the mixer volume to 0. Also always clip input volumes, and remove some minor code duplication.
| * | audio: properly restore audio volume on exit when mute is usedwm42012-01-184-13/+42
| | | | | | | | | | | | | | | | | | | | | | | | When you mute audio, mplayer is supposed to restore the volume controls on exit. This affects when --softvol isn't used and the audio output driver volume controls directly affect the system wide volume controls. This wasn't done in some cases.
| * | ao_coreaudio: signal that volume controls are not persistentwm42012-01-181-0/+2
| | | | | | | | | | | | | | | This will make the mplayer frontend restore the volume on its own when the audio device is reinitialized.
| * | mixer: restore volume with audio output drivers without persistent volumewm42012-01-183-20/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some audio outputs don't provide access to a system-wide mixer control, and do per-application audio mixing. Further, some of these forget the volume as soon as the audio device is closed. This can be annoying, because mplayer will "forget" the volume when playing a new file or when crossing ordered chapter boundaries. Support restoring the volume on audio reinitialization if an audio output driver knowingly behaves this way. (This doesn't change that mplayer never writes any settings into the config file, including volume settings.) This commit doesn't yet change any actual output driver to use this code. Hopefully make some logic in the volume restore code a bit more robust.
| * | softvol: make sure softvol settings are restored when switching audio trackswm42012-01-181-1/+1
| | | | | | | | | | | | | | | | | | At least in the case when switching to no audio track and then switching back, the volume settings were not restored with --softvol. Fix this by moving the call restoring the settings to a better place.
| * | audio: fix crash when exiting file when mute is enabledwm42012-01-181-0/+1
| | |
| * | af: print audio filter chain in verbose modewm42012-01-181-0/+35
| | | | | | | | | | | | The string format used in print_fmt() is taken from init_audio_filters().
| * | mixer: keep balance settingwm42012-01-072-0/+8
| | | | | | | | | | | | | | | | | | Similarly to the last commit, restore the balance setting when switching to a new file. Unlike the volume setting, balance is always implemented as filter, so this affects usage without --softvol too.
| * | mixer: keep user volume setting when --softvol is usedwm42012-01-073-0/+17
| | | | | | | | | | | | | | | | | | | | | | |