summaryrefslogtreecommitdiffstats
path: root/options.h
Commit message (Collapse)AuthorAgeFilesLines
* image_writer: add option parsingwm42012-08-061-3/+1
| | | | | image_writer now provides its own option parsing, and screenshot.c and the mplayer frontend use it.
* mplayer: rip out --capture supportwm42012-08-021-2/+0
| | | | | | | While this was an interesting idea, it wasn't actually useful. Basically it dumped the raw data (as requested by the demuxer) into a file. The result is only useful if the file format was raw or maybe some MPEG packet stream, but not with most modern file formats.
* mplayer: remove benchmarking/CPU accounting codewm42012-07-301-1/+1
| | | | | | | | | | The code used for benchmarking and showing CPU stats in the status line was inaccurate, misleading and fragile. The final nail in the coffin is the fact that many libav decoders are multithreaded now, and mplayer couldn't possibly measure the CPU time consumed by them. Add the --untimed option. This makes the video untimed, just like --benchmark did (still requires disabling audio synchronization).
* mplayer: remove Linux RTC supportwm42012-07-301-2/+0
| | | | | | | This used /dev/rtc for timing. /dev/rtc root only by default, and I have a hard time believing that the standard OS functions are not good enough. (Even if not, support for POSIX high resolution timers should be added instead, see clock_gettime() and others.)
* Add support for playing video from streaming sites with libquviwm42012-07-281-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This enables playing URLs from libquvi supported streaming sites directly, e.g. "mplayer http://www.youtube.com/watch?v=...." Anything opened with mplayer is checked with libquvi. If it looks like a URL of a supported streaming site, libquvi is used to extract the media URL, which is then passed to the lower level mplayer code instead of the HTML URL. Hopefully the libquvi URL checker works well enough that it doesn't cause any problems with normal URLs, files, or whatever else mplayer's stream layer accepts. Add the --libquvi-format option. the option value is directly passed to libquvi as requested format. The only values that seem to work for any streaming site seem to be "best" (best quality) and "default" (lowest quality). The mplayer option defaults to "best" (overriding libquvi's default). Outstanding issues: - Does libquvi checking every opened file really not cause problems? Should there be a runtime option to disable libquvi use? (Probably not an issue.) - Should we check/set the supported protocol? By default libquvi has support for all protocols enabled. In the worst case, it might return an URL using a protocol not supported by mplayer, even though it could extract URLs with other protocols too. (Probably not an issue.) - Somehow export metadata (like media title) to the mplayer frontend?
* Merge remote-tracking branch 'origin/master'wm42012-04-011-0/+5
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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
| * options, x11+cocoa: add option --cursor-autohide-delayStefano Pigozzi2012-03-251-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
| * options: move mixer.h options to structUoti Urpala2012-03-201-0/+4
| |
* | screenshot: make screenshot filenames configurablewm42012-02-291-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds the --screenshot-template option, which specifies a template for the filename used for a screenshot. The '%' character is parsed as format specifier. These format specifiers insert metadata into the filename. For example, '%f' is replaced with the filename of the currently played file. The following format specifiers are available: %n Insert sequence number (padded with 4 zeros), e.g. "0002". %0Nn Like %n, but pad to N zeros (N = 0 to 9). %n behaves like %04n. %#n Like %n, but reset the sequence counter on every screenshot. (Useful if other parts in the template make the resulting filename already mostly unique.) %#0Nn Use %0Nn and %#n at the same time. %f Insert filename of the currently played video. %F Like %f, but with stripped file extension ("." and rest). %p Insert current playback time, in HH:MM:SS format. %P Like %p, but adds milliseconds: HH:MM:SS.mmmm %tX Insert the current local date/time, using the date format X. X is a single letter and is passed to strftime() as "%X". E.g. "%td" inserts the number of the current day. %{prop} Insert the value of the slave property 'prop'. E.g. %{filename} is the same as %f. If the property doesn't exist or is not available, nothing is inserted, unless a fallback is specified as in %{prop:fallback text}. %% Insert the character '%'. The strings inserted by format specifiers will be checked for characters not allowed in filenames (including '/' and '\'), and replaced with the placeholder '_'. (This doesn't happen for text that was passed with the --screenshot-template option, and allows specifying a screenshot target directory by prefixing the template with a relative or absolute path.)
* | core: add option to start in paused statewm42012-02-091-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | 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.
* | screenshot: add png compression settingwm42012-01-181-0/+1
| | | | | | | | | | | | | | | | 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-181-0/+3
|/ | | | | | 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.
* options, core/hrseek: add --hr-seek-demuxer-offsetUoti Urpala2011-11-141-0/+1
| | | | | | | | | | | Some demuxers do not accurately seek to a keyframe before a given time but instead start too late. This means that precise seeks cannot work either. Most notably the libavformat mpeg demuxer exhibits this behavior depending on the file being played (with the internal mpeg demuxer precise seeks don't work at all). Add new option --hr-seek-demuxer-offset which can be used as a workaround with such demuxers. The value of the option is subtracted from the seek target position given to the demuxer when doing a precise seek.
* video, options: implement better YUV->RGB conversion controlwm42011-10-161-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rewrite control of the colorspace and input/output level parameters used in YUV-RGB conversions, replacing VO-specific suboptions with new common options and adding configuration support to more cases. Add new option --colormatrix which selects the colorspace the original video is assumed to have in YUV->RGB conversions. The default behavior changes from assuming BT.601 to colorspace autoselection between BT.601 and BT.709 using a simple heuristic based on video size. Add new options --colormatrix-input-range and --colormatrix-output-range which select input YUV and output RGB range. Disable the previously existing VO-specific colorspace and level conversion suboptions in vo_gl and vo_vdpau. Remove the "yuv_colorspace" property and replace it with one named "colormatrix" and semantics matching the new option. Add new properties matching the options for level conversion. Colorspace selection is currently supported by vo_gl, vo_vdpau, vo_xv and vf_scale, and all can change it at runtime (previously only vo_vdpau and vo_xv could). vo_vdpau now uses the same conversion matrix generation as vo_gl instead of libvdpau functionality; the main functional difference is that the "contrast" equalizer control behaves somewhat differently (it scales the Y component around 1/2 instead of around 0, so that contrast 0 makes the image gray rather than black). vo_xv does not support level conversion. vf_scale supports range setting for input, but always outputs full-range RGB. The value of the slave properties is the policy setting used for conversions. This means they can be set to any value regardless of whether the current VO supports that value or whether there currently even is any video. Possibly separate properties could be added to query the conversion actually used at the moment, if any. Because the colorspace and level settings are now set with a single VF/VO control call, the return value of that is no longer used to signal whether all the settings are actually supported. Instead code should set all the details it can support, and ignore the rest. The core will use GET_YUV_COLORSPACE to check which colorspace details have been set and which not. In other words, the return value for SET_YUV_COLORSPACE only signals whether any kind of YUV colorspace conversion handling exists at all, and VOs have to take care to return the actual state with GET_YUV_COLORSPACE instead. To be changed in later commits: add missing option documentation.
* options: move libass-related options to structUoti Urpala2011-09-031-0/+10
|
* options, subs: add --ass-vsfilter-aspect-compatharklu2011-08-121-0/+1
| | | | | | | | | Add option --ass-vsfilter-aspect-compat and corresponding property ass_vsfilter_aspect_compat. The setting controls whether to enable the emulation of traditional VSFilter behavior where subtitles are stretched if the video is anamorphic (previously always enabled for native SSA/ASS subtitles). Enabled by default. Add 'V' as a new default keybinding to toggle the property.
* core: improve --loop handlingUoti Urpala2011-07-291-0/+1
| | | | | | | | Make per-file loop option start from --ss position, not always 0. Do looping in more cases; before looping was only done when encountering real end of file, now it also happens for example at --endpos or --frames limits. Also move the --ss option to the option struct.
* subs: fix per-file --ass-force-styleUoti Urpala2011-07-231-0/+1
| | | | | | | | | | | | | The --ass-force-style option was only applied when the main libass library handle was created. Thus any per-file option changes later had no effect. Do the ass_set_style_overrides() call in per-file initialization instead so that possible changes will be applied. Also move the option variable to the option struct. Current libass will crash (usually) if you set style overrides to a nonempty value, then an empty one. It'll be easier to trigger this bug after this commit, but the problem is not on mplayer2 side. The fix is trivial so hopefully there will be a fixed libass soon.
* input: rework event reading and command queuingUoti Urpala2011-07-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rework much of the logic related to reading from event sources and queuing commands. The two biggest architecture changes are: - The code buffering keycodes in mp_fifo.c is gone. Instead key input is now immediately fed to input.c and interpreted as commands, and then the commands are buffered instead. - mp_input_get_cmd() now always tries to read every available event from every event source and convert them to (buffered) commands. Before it would only process new events until one new command became available. Some relevant behavior changes: - Before commands could be lost when stream code called mp_input_check_interrupt() which read commands (to see if they were of types that triggered aborts during slow IO tasks) and then threw them away. This was especially an issue if cache was enabled and slow to read. Fixed - now it's possible to check whether there are queued commands which will abort playback of the current file without throwing other commands away. - mp_input_check_interrupt() now prints a message if it returns true. This is especially useful because the failures caused by aborted stream reads can trigger error messages from other code that was doing the read; the new message makes it more obvious what the cause of the subsequent error messages is. - It's now possible to again avoid making stdin non-blocking (which caused some issues) without reintroducing extra latency. The change will be done in a subsequent commit. - Event sources that do not support select() should now have somewhat lower latency in certain situations as they will be checked both before and after select()/sleep in input reading; before the sleep always happened first even if such sources already had queued input. Before the key fifo was also handled in this manner (first key triggered select, but if multiple were read then rest could be delayed; however in most cases this didn't add latency in practice as after central code started doing command handling it queried for further commands with a max sleep time of 0). - Key fifo limiting is more accurate now: it now counts actual commands intead of keycodes, and all queued keys are read immediately from input devices so they can be counted correctly. - Since keypresses are now interpreted immediately, commands which change keybindings will no longer affect following keypresses that have already been read before the command is executed. This should not be an issue in practice with current keybinding behavior.
* Merge branch 'mplayer1_changes'Uoti Urpala2011-05-021-0/+1
|\
| * OSD: support displaying fractional part of current positionUoti Urpala2011-04-121-0/+1
| | | | | | | | | | | | | | | | Add option -osd-fractions which enables display of fractional seconds when showing the current playback time on OSD. Based on a patch from Christian <herr.mitterlehner@gsmpaaiml.com> but with several modifications.
* | subs: options: add -sub-pathsClément Bœsch2011-04-201-0/+1
| |
* | options: move sub_name, sub_auto and vobsub_name to structClément Bœsch2011-04-201-0/+3
| |
* | options: change -alang and -slang to use string list typeClément Bœsch2011-04-201-2/+2
|/ | | | | | | | | There is no reason to use manual language list splitting when an automatic split function is already available. Some types change from "unsigned char" to "char", but this shouldn't cause issues since [as]lang settings are unlikely to have characters above 127.
* options: move -noconfig to option struct, simplifyUoti Urpala2011-01-111-0/+1
|
* core: add support for precise non-keyframe-limited seeksUoti Urpala2010-12-201-0/+1
| | | | | | | | | | | | | Add support for seeking to an arbitrary non-keyframe position by decoding video starting from the previous keyframe. Whether to use this functionality when seeking is controlled by the new option -hr-seek and a new third argument to the "seek" command. The default is to use it for absolute seeks (like chapter seeks) but not for relative ones. Because there's currently no support for cutting encoded audio some desync is expected if encoded audio passthrough is used. Currently precise seeks always go to the first frame with timestamp equal to or greater than the target position; there's no support for "matching or earlier" backwards seeks at frame level.
* core: ordered chapters: add heuristic for merging inaccurate chaptersUoti Urpala2010-11-261-0/+1
| | | | | | | | | | Some Matroska files have inaccurate ordered chapter endpoints, and so parts where one chapter should end and the next begin at the same timestamp were not merged. This resulted in an unnecessary seek over a minimal distance. Add a heuristic to merge parts with a minimal gap or overlap between them. Based on patch by Hector Martin <hector@marcansoft.com>.
* options: more mplayer.c options moved to option structClément Bœsch2010-11-141-0/+8
| | | | | | Following options were moved: autoq, benchmark, [no]term-osd, term-osd-esc, playing-msg, [no]idle, [no]consolecontrols, list-properties.
* options: move various mplayer.c options to option structClément Bœsch2010-11-131-0/+5
| | | | | Following options were moved: [no]quiet, [no]autosync, softsleep, [no]rtc, rtc-device.
* core: do initial A-V sync by modifying audio streamUoti Urpala2010-11-131-0/+1
| | | | | | | Add code to enforce matching pts with video when (re)starting the audio stream, by either cutting away the first samples or inserting silence at the beginning. New option -noinitial-audio-sync can be used to disable this and return to old behavior.
* audio: add -gapless-audio optionUoti Urpala2010-11-121-0/+2
| | | | | | | | | If the option is enabled and all audio has been buffered to the AO, then the player will move to the next file without waiting for the buffered audio to drain, while leaving the AO initialized. If the playback of the next file starts quickly enough (before the AO buffer empties) then it should continue writing audio to the same AO with no gap in between.
* options: move -cache-min and cache-seek-min to option structClément Bœsch2010-11-111-0/+2
|
* options: move [no]hr-mp3-seek to option structClément Bœsch2010-11-111-0/+1
|
* options: move some demux options to option structClément Bœsch2010-11-111-0/+9
| | | | | Following options were moved: audiofile, audiofile-cache, subfile, demuxer, audio-demuxer, sub-demuxer, [no]extbased.
* options: move -name and -title to option structClément Bœsch2010-11-041-0/+2
|
* Add a simple capture feature (-capture)Uoti Urpala2010-11-021-0/+1
| | | | | | | | | | | | | | | | | If a specified key is pressed during playback, the current stream is captured to a file, similar to what -dumpstream achieves. original patch by Pásztor Szilárd, don tricon hu Taken from the following svn commits, but with several fixes and modifications (one obvious user-visible difference is that the default key binding is 'C', not 'c'): git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32524 b3059339-0415-0410-9bf9-f77b7e298cf2 git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32529 b3059339-0415-0410-9bf9-f77b7e298cf2 git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@32530 b3059339-0415-0410-9bf9-f77b7e298cf2
* options: move -dumpfile to option structUoti Urpala2010-11-021-0/+1
|
* options: move audio_output_channels, audio_output_format to structUoti Urpala2010-11-021-0/+2
|
* options: move -a52drc to option structUoti Urpala2010-06-021-0/+1
| | | | Also allow a range up to 2.
* options: move -alang and -slang to option structUoti Urpala2010-05-221-0/+2
| | | | | | | The option field corresponding to -slang is now called "sub_lang" instead of the old misleading global name "dvdsub_lang". The code handling -slang in subreader.c looks rather broken; disable it instead of converting it to use the option field.
* options: move -chapter values to option structUoti Urpala2010-04-251-0/+1
| | | | | | | | | | | -chapter can optionally take a range with a start and an end. Add a new option type which supports such values and use that instead of a custom per-option function. This commit also fixes a build configuration bug: before the availability of the -chapter option depended on DVD functionality being enabled in the binary, even though the option works with other sources too.
* options: move lavfdopts to option structUoti Urpala2010-04-231-0/+9
|
* Support for multiple editions in MatroskaDaniel Dawson2009-12-041-0/+1
| | | | | | | | Add code to intelligently choose an appropriate Matroska edition when there are several. Will choose, in descending order of preference: the edition chosen by the user through the option "-edition <edition id>" if it exists, the first edition with EditionFlagDefault set to 1 if there is one, or the first edition.
* options: Move ass_enabled to options structUoti Urpala2009-12-021-0/+1
|
* core: Add support for decoder reordering of pts valuesUoti Urpala2009-11-211-0/+1
| | | | | | | | | | | | | | | | | | | | | | | Add a mode where libavcodec's reordered_opaque feature is used to associate container packet timestamps with decoded frames. This should improve behavior at least for MPEG files with interlaced h264; the previous code does not cope well with the libavformat demuxer producing two field packets with separate timestamps but the libavcodec h264 decoder only producing a single output frame for those two packets (so half the timestamps have no associated output frame). The current libavformat mpeg demuxer seems to finally work with interlaced h264 files and produce valid timestamps which are useful with a mode like this. By default MPlayer now selects between this new mode and the old one automatically based on the number of timestamp problems they cause; by default the new mode is used if both seem to work. The new option -pts-association-mode can be used to force a particular mode. If correct-pts mode is disabled this has no effect on timing. Also remove the "EXPERIMENTAL" marker from the manpage description of -correct-pts.
* Merge branch 'ordered_chapters'Uoti Urpala2009-04-081-0/+4
|\
| * Add option -noordered-chapters.Uoti Urpala2009-04-081-0/+1
| |
| * options: Move osd_level and osd_duration to options structUoti Urpala2009-03-311-0/+2
| |
| * VO: Don't force window position in X11 VOsUoti Urpala2009-03-311-0/+1
| | | | | | | | | | | | | | | | | | | | Disable by default the code that forcefully moved the video output window to the middle of the screen whenever it was reconfigured or created. That behavior was really annoying when switching video streams within a file, and overriding the window manager like that is not good default behavior for the initial creation of a window either. Add a new option "-force-window-position" that can be used to restore the