aboutsummaryrefslogtreecommitdiffhomepage
Commit message (Collapse)AuthorAge
...
* client API: change description of format conversionsGravatar wm42014-02-25
| | | | | | | This changed during the time between writing the comment, and finishing up the implementation. Although I'm still unsure about this.
* config: when writing resume config, read options, not propertiesGravatar wm42014-02-25
| | | | | | | | | | | This lowers the number of data stored in the resume config a bit further, because some properties can't be read at program start and when e.g. the VO wasn't created yet. Some fields still need to be read from a property (actually only "volume-restore-data", a hack to save the full volume information). So abuse the "options/" property, and make use of the fact that changing things at runtime also changes the options.
* config: don't save options to resume-config that didn't changeGravatar wm42014-02-25
| | | | | | | | | | | | | | | | This is approximate: we read each option value on program start (before starting playback of a file), and when writing the resume config, compare each value to the current state. This also means when a value is changed and then changed back, it's not stored. In particular, option values set in config files and on the command line are considered the default. This should help reducing the numbers of options overridden by the resume config. If too much is overridden, it becomes an inconvenience, because changes in config files will apparently have no effect when resuming a file. Also see github issue #574.
* input: allow input.conf bindings to be declared as builtinGravatar wm42014-02-25
| | | | | | This might be helpful if we ever want cascading config files. Also, we will probably need it if we change the default input.conf bindings, and want to provide compatibility input.conf files.
* config: always print resolved config paths in verbose modeGravatar wm42014-02-25
| | | | | Restructure the code to make that easier. There should be no functional changes, other than the log call at the end of each function.
* manpage: remove unused environment variableGravatar wm42014-02-25
| | | | We removed gettext (which was disabled by default) a while ago.
* config: add a --config-dir option to force config directoryGravatar wm42014-02-25
| | | | Useful for slave-mode like uses, and not as radical as --no-config.
* config: don't write default config fileGravatar wm42014-02-25
| | | | | | This created an essentially empty config file. This is not really needed and probably causes more trouble than it solves (such as littering the home directory with crap), so get rid of it.
* manpage: Improve wording on icc-approx-gammaGravatar Niklas Haas2014-02-25
| | | | | This version is clearer on its origin, prevalence and use case and offers some advice to the user.
* manpage: document the new loadfile argumentGravatar wm42014-02-25
| | | | I forgot about this.
* client api examples: set an option with MPV_FORMAT_FLAGGravatar wm42014-02-24
|
* command: fix loadfile commandGravatar wm42014-02-24
| | | | | | | | | | | | | | | This was broken by commit bb6b543812a724. Note that the original pull request was fine, but it was broken by my own stupidity when I was "improving" it. The problem is that the new loadfile argument was not considered optional anymore after my changes. The original pull request did handle this by setting .defval to a dummy value, but I removed that part. Fix it again by introducing a flag that designates that the parameter is optional. (I didn't want to add it to m_option.h, because technically, all options are optional, and it's not possible to have non-optional options.)
* client API: report pause/unpause reasonGravatar wm42014-02-24
| | | | | | | | | Not sure about this... might redo. At least this provides a case of a broadcasted event, which requires per-event data allocation. See github issue #576.
* client API: expose the internal clockGravatar wm42014-02-24
| | | | | | | | | May or may not be useful in some ways. We require a context parameter for this just to be sure, even if the internal implementation currently doesn't. That's one less mpv internal function for the Lua wrapper.
* lua, osc: use properties for chapter/track listsGravatar wm42014-02-24
|
* command: make options property return the list of all optionsGravatar wm42014-02-24
|
* client API: add comment about character encoding issuesGravatar wm42014-02-24
| | | | | | Also mention that NULL isn't valid. Although I'm not sure whether the implementation strictly follows this (it should, but there are some wacky corner cases).
* lua: add a bunch of functions to get/set properties by their native typeGravatar wm42014-02-24
| | | | | | There are some complications because the client API distinguishes between integers and floats, while Lua has only "numbers" (which are usually floats). But I think this should work now.
* client API: implement setting options using their native type tooGravatar wm42014-02-24
| | | | | | | | | | | This is only half-implemented: actually the option will first be converted from mpv_node to its native type, then it's converted to a string, and then back to its native type. This is because the option API was made for strings and not anything else. Other than being grossly inelegant, the only downside is probably with string lists and key/value lists, which don't escape strings containing syntax elements correctly.
* m_property: retrieve chapter lists etc. as mpv_nodeGravatar wm42014-02-24
| | | | | | This automatically allows accessing properties like chapter-list and track-list to be read as mpv_node. This affects all properties which use m_property_read_sub() and m_property_read_list().
* client API: add support for accessing properties by their native typeGravatar wm42014-02-24
| | | | | | | | | | | | | | This actually makes use of the client.h declarations and the mpv_node mechanisms added some commits ago. For now, using MPV_FORMAT_STRING will usually fallback to explicit string conversion, but not in the other cases. E.g. reading a numeric property as string will work, but not reading a string property as number. Other than that, only MPV_FORMAT_INT64->MPV_FORMAT_DOUBLE does an automatic conversion. I'm not sure whether these semantics and API are good, so comments and suggestions are welcome.
* m_property: add mechanism to access properties as mpv_nodeGravatar wm42014-02-24
| | | | | | | | Allows retrieving properties by their native values (or something close to it), rather than having to go through string conversion. The caller could actually just copy the value itself and then use the m_option functions to convert it to mpv_node, but maybe it's more flexible this way.
* m_option: add a way to convert values to/from mpv_nodeGravatar wm42014-02-24
| | | | | | | m_option is basically the mechanism to handle C data types in a dynamic way. Add functions to convert values to and from mpv_node. For example, string lists are turned into mpv_node using MPV_FORMAT_NODE_ARRAY, and so on.
* client API: adjust error stringsGravatar wm42014-02-24
| | | | | These error codes can be used for setting and getting, not just for settings (although currently there's no API to get options directly).
* m_property: simplify some codeGravatar wm42014-02-24
|
* client API: add more data formats, add a structured data typeGravatar wm42014-02-24
| | | | | | | | | | | | | | | | | | | This adds declarations for new formats. The implementation will be added in the following commits. (It still compiles and runs with this commit, because it adds constants only.) The obvious new types are MPV_FORMAT_FLAG, MPV_FORMAT_INT64, MPV_FORMAT_DOUBLE. MPV_FORMAT_FLAG is a boolean, but to avoid nasty ABI issues or with languages that don't have a bool data type (C89), it uses int. Thus the format is not named MPV_FORMAT_BOOL, to avoid confusion. The MPV_FORMAT_NONE type (mpv_node) is a generic structured type, like a variant or, say, JSON. It can store strings/bools/numbers, as well as arrays and key/value pairs (with string keys only). The MPV_FORMAT_NODE_ARRAY and MPV_FORMAT_NODE_MAP types are used internally by mpv_node only and can't be used with most of the other API (like mpv_set_property()) directly.
* client API: change semantics for MPV_FORMAT_STRINGGravatar wm42014-02-24
| | | | | | | | | | | | With mpv_set_property(h, "property", MPV_FORMAT_STRING, ptr), ptr now has to be of type char** instead of char*. This makes it more consistent with mpv_get_property() and also non-pointer formats, which will be introduced in the following commits. mpv_set_property() of course does not change its interface (only its implementation is adjusted to keep its interface). This also affects mpv_set_option(), but again not mpv_set_option_string().
* client API: fix a typoGravatar wm42014-02-24
|
* client API: remove trailing "," from enumsGravatar wm42014-02-24
| | | | | | | This is allowed in C99 and C++11, but apparently not in C89 and C++98. Make it conform to the older standards, since we want the client API header to be highly portable.
* client API: spellingGravatar wm42014-02-24
|
* vdpau: change the error message when video too largeGravatar Andrey Morozov2014-02-24
|
* vo_opengl: Add :icc-approx-gamma suboption to approximate BT.709 gammaGravatar Niklas Haas2014-02-24
| | | | | | This uses the value of 1.95 as an approximation for the exact gamma curve, which replicates the behavior of popular video software including anything in the Apple ecosystem, as per issue #534.
* m_option: fix printf format specifierGravatar wm42014-02-24
|
* configure: fix typoGravatar Nyx0uf2014-02-24
| | | | When using help, the output for --enable-shared was : `--enable-shared enable enable shared library [disable]`
* dvd: treat missing volume ID as "unsupported", not errorGravatar wm42014-02-23
| | | | | This is probably better and more consistent with the rest of the code, although it doesn't change any currently existing behavior in this case.
* cache: cache DVD volume IDGravatar wm42014-02-23
| | | | | Since this might be queried every frame or so, it's important not to stall the cache by doing a synchronous stream_control().
* dvd: check for empty DVD volume IDGravatar wm42014-02-23
| | | | | The only DVD sample I have just returns an empty string for this. Let command.c use the filename if the ID is empty.
* command: use DVD volume ID for media-title propertyGravatar xylosper2014-02-23
| | | | | | Signed-off-by: wm4 <wm4@nowhere> Closes #582.
* example.conf: change subtitle codepage example to use UTF-8 fallbackGravatar wm42014-02-23
| | | | This should be pretty safe compared to forcing the codepage.
* example.conf: subtitle encodingGravatar Yaser Alraddadi2014-02-23
| | | | | | Signed-off-by: wm4 <wm4@nowhere> Closes #580.
* command: provide per-file-options for loadfile commandGravatar xylosper2014-02-23
| | | | | | Signed-off-by: wm4 <wm4@nowhere> Closes #575. Minor changes over original pull request.
* command: remove special casing for strings in input commandsGravatar wm42014-02-23
| | | | | | Until now, strings were the only allowed dynamically allocated argument type in input commands. Extend it so that it works for any type. (The string expansion in command.c is of course still string specific.)
* old build: add a missing config.h defineGravatar wm42014-02-23
| | | | The configure check was added to waf only.
* ta: fix commentGravatar wm42014-02-23
| | | | | | If this function could return the input value (i.e. the == case was correct), then macros like MP_GROW_ARRAY would have been incorrect. The implementation was correct though, so there's no bug.
* ta: clarify a corner caseGravatar wm42014-02-23
|
* manpage: fix a metadata property nameGravatar wm42014-02-23
|
* command: don't use option name in propertiesGravatar wm42014-02-23
| | | | | | | | | | | | | Some code accessed m_option.name to get the property name. (Maybe only show_property_osd() had a significant use of it.) Remove that, and remove setting names and dummy names as well. The old code usually assumed that the name was set, and show_property_osd() used it to get the proper name of deprecated aliases. The "vf" property was listed as "vf*". Not sure why that was done, but it works without anyway.
* manpage: fix yadif example in one caseGravatar wm42014-02-23
|
* m_option: explicitly allow m_option.name==NULLGravatar wm42014-02-23
| | | | | | | | Doesn't require other code to care about this, which will allow us to simplify the property code. Only "wildcard" options like "vf" and string lists used this, and m_option_list_findb() (which is excused).
* lua: fix behavior if no script command handler is registeredGravatar wm42014-02-23
|