INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Issue: MC26 GUI issue with MadVR adjusting image resolution and or aspect ratio  (Read 4733 times)

Movieman

  • World Citizen
  • ***
  • Posts: 113

I am seeing issues with the top control bar (see attachment for the issue) in two specific environments;

1:  Using a 3840x2160 desktop resolution and using the MadVR display mode switching to select either 1920x1080 23Hz or 1920x1080 29Hz resolutions on an LCD display.

2:  Using MadVR anamorphic lens corrections on a JVC LCOS projector.

It appears to me that the position and size of the top bar are predetermined based on the display resolution and aspect ratio in effect before MadVR makes it's modifications.

Once MadVR switches the display to a different resolution, or changes the aspect ratio to accommodate an anamorphic lens, the bar is no longer usable as both the size of the bar and the location of the clickable areas are no longer correct.

The attachment shows the problem after MadVR has changed the desktop resolution from 3840x2160 to 1920x1080.

I'm not sure how difficult the coding would be, but it seems that the on screen GUI would need to be dynamically verified and modified after any MadVR changes to the image.

Also, on a different (but related) topic, we front projection constant height users are still waiting for the implementation of user defined presets assignable to hotkeys for the zoom function. It's pretty ugly to have to hold down the "i" key for a period of time, only to overshoot the desired zoom and have to correct, instead of having a set of user defined hot keys to handle the various aspect ratios.  We certainly appreciate the tools that MadVR brings, but they fall short of other players support (examples being MPC, Zoom Player,  VLC).

Thanks again for a great product.

Logged

wer

  • Citizen of the Universe
  • *****
  • Posts: 2640

You can let MC control the actual resolution changes, instead of having MadVR do it.  That tends to be more reliable.
Logged

Hendrik

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10923

I would generally advise against resolution changes for video playback. Let madVR handle the upscaling, it'll do a better job then your TV, and changing resolution has some headaches.
Logged
~ nevcairiel
~ Author of LAV Filters

wer

  • Citizen of the Universe
  • *****
  • Posts: 2640

He IS changing the resolution, but looks like he's really making the change because of the refresh rate; he has to change modes to get to 23.976 regardless.  I was using "resolution change" in that generic sense of mode change: resolution and refresh rate.

But Hendrik's right; if your PC is fast enough, you should change only the refresh rate and not the resolution.
Logged

Movieman

  • World Citizen
  • ***
  • Posts: 113

Quote
You can let MC control the actual resolution changes, instead of having MadVR do it.  That tends to be more reliable.

Sorry, I may be missing something here, but AFAIK the functions and flexibility I need are simply not available in MC without using MadVR.

For example I need a custom correction factor to compensate for my anamorphic lens' 1.5X expansion.  I's not a typical 1.33x expansion lens, as my screen has an AR of 2.76:1.

You simply cannot depend on black bar detection, and there is no flagging on a disc to indicate if a blue ray is sourced from a 1.85:1, 2.00:1, 2.20:1, 2.40:1, 2.55:1, 2.65:1, or 2.76:1 film element.

Back in 2014 https://yabb.jriver.com/interact/index.php?topic=89083.0 this was discussed in detail, and the recommendation was that MC would use MadVR for full support of this environment.

So, I'm hoping that the MC developers will address the issue as stated.


Logged

Movieman

  • World Citizen
  • ***
  • Posts: 113

Quote
I would generally advise against resolution changes for video playback.
Except you have to do that when you're playing a frame packed 3D Blue ray on a 4K Display or projector that requires 23.976 1920x1080 input for 3D.
Logged

Hendrik

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 10923

So, I'm hoping that the MC developers will address the issue as stated.

Unfortunately, thats not very likely for the forseeable future. Changing resolution mid-playback runs into various limitations with Windows DPI handling and how MCs window drawing was developed. It would require a massive internal redesign which is a very long-term project, and not a quick fix.

As such, we cannot recommend resolution changes. Or you can use the OSD, which I believe should scale better.
Logged
~ nevcairiel
~ Author of LAV Filters

wer

  • Citizen of the Universe
  • *****
  • Posts: 2640

Sorry, I may be missing something here, but AFAIK the functions and flexibility I need are simply not available in MC without using MadVR.

I think the thing you're missing is that you can have MC perform resolution and refresh rate changes, while letting MadVR do everything else.

Even if MC cannot automagically detect the resolution or refresh rate settings you desire for a particular movie, you can use any field you want (or a combination, or custom fields) to trigger a zone switch , and through ZoneSwitch, you will have absolute control of the resolutions and/or refresh rates used.

The only complication is that by default your video driver expects square pixels.  Even when MadVR is running with the anamorphic correction on, your Video Card believes it is (and IS) outputting square pixels.  MadVR is distorting the image and mapping a non-square-pixel image onto the square pixel grid that is transmitted over the HDMI, to compensate for the distortion caused by your lens.  Anamorphic projection is inherently non-square-pixels.

If you really want your video card to be able to understand what's happening, you would have to configure a custom resolution with non-square pixels and custom timings.  Not sure if your video driver will support that.  The MadVR option you're using exists for cards that can't.
Logged

Movieman

  • World Citizen
  • ***
  • Posts: 113

OK, sorry to hear that.
Seems to me that the resolution change occurs before playback actually starts, not mid playback.

Quote
Or you can use the OSD
Which OSD is that?

Do you think settable presets with hot keys for zoom would be possible in the near future?  It's been requested for quite a while now.

Logged

Movieman

  • World Citizen
  • ***
  • Posts: 113

Quote
you can use any field you want (or a combination, or custom fields) to trigger a zone switch , and through ZoneSwitch, you will have absolute control of the resolutions and/or refresh rates used.

How do you apply a zone switch to a physical Blue ray disc?
Logged

wer

  • Citizen of the Universe
  • *****
  • Posts: 2640

That's something new you've added in.  You didn't say previously it was a physical disc.

Zone Switch works best for items in the library, as they have fields.  For things not in the library, you can have rules based on the physical path, or other properties of the file that can be detected.

Or you could rip to an ISO if you want menus, or to MKV if you just want the movie.  If you don't rip, there are limitations.

Also, by the way, you CAN have hotkeys, or remote commands, for controlling the zoom function.
You should research Media Center Core Commands (MCC) and pay attention to 22025 and 22026.

Good luck.
Logged

Movieman

  • World Citizen
  • ***
  • Posts: 113

Quote
Also, by the way, you CAN have hotkeys, or remote commands, for controlling the zoom function.
You should research Media Center Core Commands (MCC) and pay attention to 22025 and 22026.

I have researched them, and they are non functional for my purpose and environment.  As far as I can determine, 22025 doesn't take effect at initial launch unlike, for example VLC

"D:\Apps\VLC 3.10\vlc\vlc.exe" --monitor-par 23:16 --zoom 1.35 --fullscreen

and since MC occupies the entire screen when playing video, it's hard to run a command line window without a second monitor, which isn't going to fly in an Home Theater environment.

MPC:

[HKEY_CURRENT_USER\Software\MPC-HC\MPC-HC\Settings\PnSPresets]
"Preset0"="1.77,0.500,0.500,0.700,1.000"
"Preset1"="1.85,0.500,0.500,0.720,1.037"
"Preset2"="2.00,0.500,0.500,0.780,1.126"
"Preset3"="2.20,0.500,0.500,0.860,1.243"
"Preset4"="2.40,0.500,0.500,0.925,1.349"
"Preset5"="2.55,0.500,0.500,0.970,1.430"
"Preset6"="2.76,0.500,0.500,1.070,1.550"

Zoom Player

[HKEY_CURRENT_USER\Software\VirtuaMedia\ZoomPlayer]
"Preset2"="2: XOfs[268] YOfs[-20] Width[1384] Height[1120]"
"PresetCustomAR2"="2: Width[1.77] Height[1]"
"Preset3"="3: XOfs[228] YOfs[-70] Width[1460] Height[1230]"
"PresetCustomAR3"="3: Width[1.85] Height[1]"
"Preset4"="4: XOfs[140] YOfs[-130] Width[1640] Height[1340]"
"Preset5"="5: XOfs[60] YOfs[-188] Width[1800] Height[1460]"
"PresetCustomAR5"="5: Width[2.20] Height[1]"
"Preset6"="6: XOfs[30] YOfs[-237] Width[1860] Height[1550]"
"PresetCustomAR6"="6: Width[2.40] Height[1]"
"Preset7"="7: XOfs[-27] YOfs[-300] Width[1980] Height[1680]"
"PresetCustomAR7"="7: Width[2.55] Height[1]"
"Preset8"="8: XOfs[-72] YOfs[-330] Width[2060] Height[1720]"
"PresetCustomAR8"="8: Width[2.76] Height[1]"
"Preset9"="9: XOfs[-92] YOfs[-340] Width[2100] Height[1740]"
"PresetCustomAR9"="9: Width[2.85] Height[1]"
Logged

wer

  • Citizen of the Universe
  • *****
  • Posts: 2640

I'm beginning to wonder why you came here asking for help when you are so sure of your own counsel.

And your continual movement of the goalposts is wearing me out.  You asked about hotkeys.  Do you know what that word means?  I wonder, because now you're switching it to launch-time parameters.  If you only wanted launch time parameters, don't waste our time asking about hotkeys.

Hotkeys activate when pressed. The conclusions you reached from your research are wrong.  The MCC commands I referred you to can be activated at ANY time when MC is running, without accessing the command line, by using a HOTKEY or by using a remote control.  I assumed you knew what a hotkey was since you were asking for it, but evidently you need to be educated about hotkeys with MC as well. You could have found this by googling "jriver hotkeys" but doubtless you saw no need to do that.
Go look at this link:
https://wiki.jriver.com/index.php/User_Defined_Global_Keyboard_Shortcuts

Now combine that knowledge with the MCC info you "researched" and realize that you can assign ANY mcc command with its parameters to a hotkey.  Also realize that you can assign ANY mcc command to a remote control input by using the dialog found at Options->Remote Control-Commands.

I use hotkeys and remote commands, in a home theater environment, without accessing the command line, and have been for years, as have many others here.  It happens instantly in the background without disrupting playback. I use it to control zooming. I use it to control cropping. So it does fly.  You're just wrong.

I'm not going to invest my time in typing out the exact config file lines you need to map specific zoom and crop actions to specific hotkeys, because you would probably just move the goalposts again.

Good luck achieving what you want.

Logged

Movieman

  • World Citizen
  • ***
  • Posts: 113

Quote
I'm not going to invest my time in typing out the exact config file lines you need to map specific zoom and crop actions to specific hotkeys, because you would probably just move the goalposts again.

Good luck achieving what you want.

Your comments were rather inappropriate IMHO. I have been an I.T. professional for 45+ years and have 55+ years of experience in the AV field.

If you had invested any time, you would possibly have found out that the feature added in this change appears to be broken. 
Code: [Select]
21.0.38 (1/18/2016)
9. NEW: Added MCC_PLAYBACK_ENGINE_VIDEO_ZOOM (28038) to set the zoom for a playing video.
28038 MCC_PLAYBACK_ENGINE_VIDEO_ZOOM int nZoomAmount (100 is 1.0)

My custom resources file:

Code: [Select]
<ACCELERATORS>
<!-- Playback engine Zoom custom shortcuts (shared) -->
<Entry TranslateFlags="32" Param="100" Command="28038" Key="Alt;F1"/>
<Entry TranslateFlags="32" Param="130" Command="28038" Key="Alt;F2"/>
<Entry TranslateFlags="32" Param="150" Command="28038" Key="Alt;F3"/>
</ACCELERATORS>

When that failed to work, I modified the default resources file which also failed to work.  Then, to make sure that it wasn't an issue with a existing key conflict I commented out two existing entries for the + and - keys and substituted my additions for them):

Code: [Select]
    <!-- Global shortcuts -->
    <Entry Key="Ctrl;Shift;F12" Command="25015" Param="1" Global="1" />

    <!-- Playback engine Zoom custom shortcuts (shared) -->
    <!-- <Entry Key="Alt;F1" Command="28038" Param="100" TranslateFlags="32" /> -->
    <Entry Key="+" Command="28038" Param="150" TranslateFlags="32" />
    <Entry Key="-" Command="28038" Param="250" TranslateFlags="32" />

    <!-- Playback engine shortcuts (shared) -->
    <!-- <Entry Key="+" Command="28000" TranslateFlags="32" /> -->
    <Entry Key="I" Command="28000" TranslateFlags="32" />
    <!-- <Entry Key="-" Command="28001" TranslateFlags="32" /> -->
    <Entry Key="O" Command="28001" TranslateFlags="32" />

Still no success with setting a specific zoom.

So, could we please get a developer to see if there was a possible regression or other issue that has disabled or broken the 28038 MCC code function?

Environment:
MC 26
Windows 8.1
NVidia GT 1030 Driver 425.31
DirectX 11

Thanks

Logged

tij

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1563

I am seeing issues with the top control bar (see attachment for the issue) in two specific environments;

1:  Using a 3840x2160 desktop resolution and using the MadVR display mode switching to select either 1920x1080 23Hz or 1920x1080 29Hz resolutions on an LCD display.

2:  Using MadVR anamorphic lens corrections on a JVC LCOS projector.

It appears to me that the position and size of the top bar are predetermined based on the display resolution and aspect ratio in effect before MadVR makes it's modifications.

Once MadVR switches the display to a different resolution, or changes the aspect ratio to accommodate an anamorphic lens, the bar is no longer usable as both the size of the bar and the location of the clickable areas are no longer correct.

The attachment shows the problem after MadVR has changed the desktop resolution from 3840x2160 to 1920x1080.

I'm not sure how difficult the coding would be, but it seems that the on screen GUI would need to be dynamically verified and modified after any MadVR changes to the image.

Also, on a different (but related) topic, we front projection constant height users are still waiting for the implementation of user defined presets assignable to hotkeys for the zoom function. It's pretty ugly to have to hold down the "i" key for a period of time, only to overshoot the desired zoom and have to correct, instead of having a set of user defined hot keys to handle the various aspect ratios.  We certainly appreciate the tools that MadVR brings, but they fall short of other players support (examples being MPC, Zoom Player,  VLC).

Thanks again for a great product.

That behavior is related to DPI setting of Windows (just tested myself) ... if you set your Windows Display properties you scale 100% ... this will not happen BUT your windows text will be puny and unreadable at 4K resolution.

Only reason I am aware of this problem is cause I output 3D in 1080p frame pack. If you don’t watch 3D, the easiest way to avoid that is not to switch to 1080p and just leave everything running at 4K (let MadVR do upscaling from HD to UHD ... I highly doubt anything come close to scaling quality of MadVR)

If you REALLY want to switch resolution and avoid that problem ... there is a way, but for the purpose of not confusing less advance users I won’t post it on forum ... PM me if you are still interested

EDIT: that bar at the top is not really needed for HTPC as mouse is often not use for HTPC ... whatever that bar can do can be achieved with MC OSD navigation that uses up/down/left/right arrows and Enter, which are easily mapped to remote control buttons

Though ... if you use MadVR ... that DPI setting can be problematic as MadVR will scale video by DPI percentage then something else scale it back to desired resolution (check MadVR OSD to see it)
Logged
HTPC: Win11 Pro, MC: latest 31(64b), NV Driver: v425.31, CPU: i9-12900K, 32GB RAM, GeForce: 2080ti
Screen: LG 2016 E6
NAS: FreeNAS 11.1, SuperMicro SSG-5048R-E1CR36L, E5-1620v4, 64GB ECC RAM, 18xUltrastar He12-SAS3 drives, 2x240GB SSD (OS)

Movieman

  • World Citizen
  • ***
  • Posts: 113

Quote
That behavior is related to DPI setting of Windows (just tested myself) ... if you set your Windows Display properties you scale 100% ... this will not happen BUT your windows text will be puny and unreadable at 4K resolution.

Actually it's not only related to the DPI settings.  ANY modification of the image by MadVR will cause this.  Something as simple as specifying the Anamorphic Lens option that shows once you select the "Digital Projector" option on MadVR and setting a non 4x3 value will cause the same issue.

Pure and simple, it relates to MC assuming that the screen area that corresponds to the native display resolution is the proper area to base it's GUI on.  However, once MadVR makes any kind of changes to the displayed image, this assumption is now invalid.

I know fixing this would be a challenge to the developers, but they put themselves in this position by choosing MadVR as the  preferred renderer.  (I agree the choice was made for good reason as MadVR is clearly the best renderer in the market.)

Unfortunately it simply doesn't work well for at least two subsets of MadVR users:

1. 3D with a 4K display
2. home theater users with an anamorphic lens.
Logged

tij

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1563

Just try setting your Windows Scale text to 100% ... and see if that bar is still usable

EDIT: that settings is Windows  setting (not MC setting) found in Display setting of Windows OS
Logged
HTPC: Win11 Pro, MC: latest 31(64b), NV Driver: v425.31, CPU: i9-12900K, 32GB RAM, GeForce: 2080ti
Screen: LG 2016 E6
NAS: FreeNAS 11.1, SuperMicro SSG-5048R-E1CR36L, E5-1620v4, 64GB ECC RAM, 18xUltrastar He12-SAS3 drives, 2x240GB SSD (OS)

Movieman

  • World Citizen
  • ***
  • Posts: 113

Windows 8.1 here, not Windows 10.  Don't see that option under Windows - Text.

Logged

tij

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1563

www.ghacks.net/2013/07/20/how-dpi-scaling-works-in-windows-8-1/amp/

EDIT: I am pulling terns from my head ... sorry ... above link says how to do that
Logged
HTPC: Win11 Pro, MC: latest 31(64b), NV Driver: v425.31, CPU: i9-12900K, 32GB RAM, GeForce: 2080ti
Screen: LG 2016 E6
NAS: FreeNAS 11.1, SuperMicro SSG-5048R-E1CR36L, E5-1620v4, 64GB ECC RAM, 18xUltrastar He12-SAS3 drives, 2x240GB SSD (OS)

Movieman

  • World Citizen
  • ***
  • Posts: 113

Sorry, at 100% everything (icons, text, etc) is unusable, just too small on my Samsung 55" curved display at 24" viewing distance. Running at 3840 x 2160 resolution. My control panel has the slider, but no description radio buttons.  I'm running with the slider 1 notch from the right.
Logged

tij

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1563

I know it’s small ... but does that top control bar shows correctly when playing movie that switched resolution
Logged
HTPC: Win11 Pro, MC: latest 31(64b), NV Driver: v425.31, CPU: i9-12900K, 32GB RAM, GeForce: 2080ti
Screen: LG 2016 E6
NAS: FreeNAS 11.1, SuperMicro SSG-5048R-E1CR36L, E5-1620v4, 64GB ECC RAM, 18xUltrastar He12-SAS3 drives, 2x240GB SSD (OS)

Movieman

  • World Citizen
  • ***
  • Posts: 113

I think I found the solution to the GUI issue:

In MadVR display modes, make sure to choose ...
when media player goes fullscreen option
when media player leaves fullscreen option

Do NOT choose ... when playback starts option
Do NOT choose ... when media player is closed option

This seemed to solve this issue for me.

Logged

Movieman

  • World Citizen
  • ***
  • Posts: 113

Update on my progress on this issue:

First my custom resource file for anyone else who may be struggling with this:

Code: [Select]
<!--
Media Center Resource XML (Default / English)
-->

<MJRS version="1.0">

<!--
COMMANDS:

  Command: the MCC command index
  Text: the string to be used in menus, etc.
  Param: the parameter for the MCC command (leave empty if param doesn't matter)
 
  Text Tokens: [Product Name], [Character]
-->

<!--
ACCELERATORS:

  Key: semi-colon delimited list of key strokes to be pressed (see list below for special keys)
    note that the only valid combinations are: [Key], [Key];Ctrl, [Key];Ctrl;Shift, [Key];Alt
  Type: the type of command (defaults to MCC)
    MCC: the command is an MC command
    Program: the command is a program to run
  Command: the MCC command index / name of program
  Param: the parameter for the MCC command / program arguments
  TranslateFlags: flags that determine when and how an accelerator is translated (binary or'd together)
    1: don't translate in edits, comboboxes, and other data entry controls
    2: don't translate in fullscreen mode or theater view
    4: don't translate in any type of popup window
    8: only translate in fullscreen
    16: don't translate in IE, VB controls, or other unknown rich controls
    32: targets playback engine / display (DVD, image playback, etc.)
    64: only translate when Action Window is focused
    128: not in Theater View
    256: not in report controls
    512: not in web browser
    1024: not in video player
  NoShowAsShortcut: 1 if you don't want MC to show this shortcut in menus, tooltips, etc.
  Global: 1 if you want the accelerator to be translated even when MC doesn't have the focus
 
  Special key list: Insert, Delete, -, +, Right, Left, Up, Down,
    NumPad0, NumPad1, NumPad2 (etc.), F1, F2, F3 (etc.), Backspace, Enter, Escape,
    Apps, Page Up, Page Down, Home, End, Space, Print Screen, Tab, Multiply ('*' on NumPad),
    Decimal ('.' on NumPad)

  Remember that order is relevant when the same shortcut appears multiple times.

  MadVR Anamorphic lens correction = 13/9
-->

  <ACCELERATORS>

    <!-- Playback engine Zoom custom shortcuts (shared) -->
    <Entry Key="Alt;A" Command="28038" Param="100" />  <!-- 1.77:1 -->
    <Entry Key="Alt;S" Command="28038" Param="96" />   <!-- 1.85:1 -->
    <Entry Key="Alt;D" Command="28038" Param="86" />   <!-- 2.00:1 -->
    <Entry Key="Alt;G" Command="28038" Param="79" />   <!-- 2.20:1 -->
    <Entry Key="Alt;H" Command="28038" Param="74" />   <!-- 2.40:1 -->
    <Entry Key="Alt;J" Command="28038" Param="69" />   <!-- 2.55:1 -->
    <Entry Key="Alt;K" Command="28038" Param="64" />   <!-- 2.76:1 -->
    <Entry Key="Alt;L" Command="28038" Param="59" />   <!-- 2.85:1 -->
  </ACCELERATORS>

</MJRS>

First things first:
A very obscure implementation, where

1. the Parameter actually decreases in value as the zoom increases and the value seems to have very little  relation to actual zoom percentage shown on the GUI when the i / o zoom option is used
2. the parameter is required to be an integer, which does not allow for sufficient granularity in the sizing of the image.
3. For some obscure reason, a value of 80 doesn't seem to give a valid zoom. (Not sure about this one as I haven't tested it recently.)

So, while the function is there, it certainly could do with some enhancements.

For now, I am certainly happy to have the capability, but I often have to use the i / o keys to fine tune the image size to establish the exact zoom amount to completely eliminate the black bars without eliminating any of the image.
Logged
Pages: [1]   Go Up