Jump to content

interesting quirk on how DCS sets origin for monitor config


skypickle

Recommended Posts

When all monitors are lined up, the location (0,0) is at the top left. So for example in this array

Untitled2.jpg

monitor 1: 3840 x 1600

monitor 2: 4096 x 2160

monitor 3: 1920 x 1080

So to use monitor 2 as the DCS game window I specify monitor config to be

_  = function(p) return p; end;
name = _('Camera + 2 MFCDsLG-Hh');
Description = '2 MFCDs on the bottom and camera on the top'
Viewports =
{
     Center =
     {
          x = 3840;
          y = 0;
          width  = 4096;
          height = 2160;
          viewDx = 0;
          viewDy = 0;
          aspect = 4096 / 2160;
     }
}

LEFT_MFCD =
{
     x = 3840 + 4096+20;
     y = 1080 + 240;
     width = 810;
     height = 810;
}
RIGHT_MFCD =
{
     x = 3840 + 4096 + 1080;
     y = 1080 + 240;
     width = 810;
     height = 810;
}

GUI = 
{
      x = 3840;
      y = 0;
      width = 4096;
      height = 2160;
}

UIMainView = GUI
GU_MAIN_VIEWPORT = Viewports.Center

but this gives me the weird result on monitor 2Untitled3.jpg:And when DCS is in focus, monitor 1 is black - I cannot read any browser I might have pulled up there.

 

However when I specify this display config:

Untitled.jpg

I can start counting my monitor config from the top left of monitor 2 and this config file:

_  = function(p) return p; end;
name = _('Camera + 2 MFCDsLG');
Description = '2 MFCDs on the bottom and camera on the top'
Viewports =
{
     Center =
     {
          x = 0;
          y = 0;
          width  = 4096;
          height = 2160;
          viewDx = 0;
          viewDy = 0;
          aspect = 4096 / 2160;
     }
}

LEFT_MFCD =
{
     x = 20;
     y = 2160 + 240;
     width = 810;
     height = 810;
}
RIGHT_MFCD =
{
     x = 1080;
     y = 2160 + 240;
     width = 810;
     height = 810;
}

GUI = 
{
      x = 0;
      y = 0;
      width = 4096;
      height = 2160;
}

UIMainView = GUI
GU_MAIN_VIEWPORT = Viewports.Center

I get the main DCS game window on monitor 2 and the MFDs on monitor 3. The number of pixels rendered in this arrangement is 4096 x 3420=14,008,320

So it seems DCS sets (0,0) to the corner of the largest monitor.

 

I realize I could shift monitor 3 all the way to the right in the display settings then I could make a monitor config with fewer total pixels for 2 and 3. (4096 +1920   x    2160  = 12,994,560) But that would confound me having to move my mouse to the right to get to monitor 1 when it is physically located to the left. 

4930K @ 4.5, 32g ram, TitanPascal

Link to comment
Share on other sites

Your total screen size as laid out, as far as dcs is concerned is 9496x2160.  Your lua setup in the first pictures seems correct except instead of the coordinates reading x=3840+4096+20, y=1080+240. Its possible i needs to  be full numbers x=7956, y=1320 since Dcs sees it all as one giant monitor.

Make sure the correct screen style is selected( lmfd+center+rmfd) or whichever file you modified. Screen size set to 9496x2160( let it pick the aspect ratio).

And most important make sure full screen is unchecked, it needs to run in “ windowed mode”. 

I lined my monitors up in windows on the left side, from largest to smallest. Just to take some of the math out.( I only use the other monitors for dcs so I don’t care how they’re laid out). Obviously that doesn’t work well for general computing but dcs doesn’t care since its coordinate based anyway. 

Also make sure the monitors in windows setup are set to 100% scale and full native resolution. 

It can be tricky to get just right. It is possible that dcs somehow wants the largest monitor at the top and left so the coordinates 0,0 do start on an actul screen, not in negative space, but I’m not 100% sure.


Edited by MadKreator

Intel i7 13700k, ASUS  rog strix z790A, 64gigs G.Skill Trident DDR5 @6400Mhz, Nvidia  RTX 4080FE, 2x 2TB Samsung M.2 NVME, 2x 1TB Samsung SSD,  Corsair RM1000x, Corsair h100i 240mm cooler, Lian Li LanCool 3, VKB Gunfighter Ultimate, VKB STECS , MFG Crosswinds, Track IR5, 48” LG UltraGear OLED & HP 24” touchscreen for Helios, Streamdeck XL, DCS-UFC App, Corsair Virtuoso RGB Headphones

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...