summaryrefslogtreecommitdiffstats
path: root/video/out/win_state.c
Commit message (Collapse)AuthorAgeFilesLines
* video: change some remaining vo_opengl mentions to vo_gpuAkemi2018-01-201-2/+2
|
* win_state: change license to LGPLwm42017-06-171-7/+7
| | | | | | All relevant authors have agreed. Also correct an unrelated entry in the "Copyright" file.
* x11: pseudo HiDPI scalingwm42017-01-191-4/+17
| | | | | | | | | | | | | | | | Scale the window by the assumed DPI scaling factor, using 96 DPI as base. For example, a screen that reports 192 DPI is assumed to have a DPI scale factor 2. The window will then be created with twice the size. For robustness reasons, we accept only integer DPI scales between 1 and 9. We also error out if the X and Y scales are very different, as this most likely indicates a multiscreen system with botched size reporting. I'm not sure if reading the X server's DPI is such a good idea - maybe the Xrdb "Xft.dpi" value should be used instead. The current method follows what xdpyinfo does. This can be disabled with --hidpi-window-scale=no.
* Apply autofit-larger after autofit-smallerNils Maier2016-11-031-1/+1
| | | | | | This prevents the window scaling beyond screen dimensions Fixes #3753
* video: switch from using display aspect to sample aspectwm42015-12-191-3/+3
| | | | | | | | | | | | | | | | MPlayer traditionally always used the display aspect ratio, e.g. 16:9, while FFmpeg uses the sample (aka pixel) aspect ratio. Both have a bunch of advantages and disadvantages. Actually, it seems using sample aspect ratio is generally nicer. The main reason for the change is making mpv closer to how FFmpeg works in order to make life easier. It's also nice that everything uses integer fractions instead of floats now (except --video-aspect option/property). Note that there is at least 1 user-visible change: vf_dsize now does not set the display size, only the display aspect ratio. This is because the image_params d_w/d_h fields did not just set the display aspect, but also the size (except in encoding mode).
* player: add --window-scale optionwm42015-04-241-0/+2
| | | | Requested. Works similar to the property with the same name.
* player: add --autofit-smaller optionwm42015-01-161-5/+9
| | | | | | | | Fixes #1472. (Maybe these options should have been named --autofit-max and --autofit-min, but since --autofit-larger already exists, use --autofit-smaller for symmetry.)
* video/out/win_state.c: fix --monitoraspectSoeren D. Schulze2015-01-051-1/+1
|
* video/out: separate out code to compute window sizewm42014-05-061-0/+123
Currently, vo_reconfig() calculates the requested window size and sets the vo->dwidth/dheight fields _if_ VOCTRL_UPDATE_SCREENINFO is implemented by the VO or the windowing backend. The window size can be different from the display size if e.g. the --geometry option is used. It will also set the vo->dx/dy fields and read vo->xinerama_x/y. It turned out that this is very backwards and actually requires the windowing backends to workaround these things. There's also MPOpts.screenwidth/screenheight, which used to map to actual options, but is now used only to communicate the screen size to the vo.c code calculating the window size and position. Change this by making the window geometry calculations available as separate functions. This commit doesn't change any VO code yet, and just emulates the old way using the new functions. VO code will remove its usage of VOCTRL_UPDATE_SCREENINFO and use the new functions directly.