Jump to content

Wrong viewports on second screen


Recommended Posts

I've been getting back into dcs with 2.5 and forgotten all I knew about multi monitor setup. I've managed to get my own .lua outputting shkval and abris to second monitor (left_mfcd & right_mfcd), but they all show copies of the main cockpit view, not what they're supposed to. Not got code handy but thought someone might know what I've done wrong?

Oh and what do you call the controller view( rt-ctrl +enter) in .lua speak? In the shark, that's handy to have on 2nd screen too.

 

Sent from my SM-G950F using Tapatalk

[sIGPIC][/sIGPIC]

i7 9700k | 32gb DDR4 | Geforce 2080ti | TrackIR 5 | Rift S | HOTAS WARTHOG | CH PRO Pedals

Link to comment
Share on other sites

You need to post your lua file for us to see.

 

Based on standard "3 cameras.lua". "," after each section copied from original. I don't believe they were used back on 1.0 the last time I did any of this stuff.

Interestingly the commented out section at the bottom seems to indicate ED have a new way of doing this but the example isn't complete.

 

_ = function(p) return p; end;

name = _('Colins Setup');

Description = 'Configuration with 3 identical monitors each with its own camera'

Viewports =

{

Center =

{

x = 1920;

y = 0;

width = 2560;

height = 1440;

viewDx = 0;

viewDy = 0;

aspect = 1.77777;

 

},

 

LEFT_MFCD =

{

x = 960;

y = 300;

width = 960;

height = 600;

},

 

RIGHT_MFCD =

{

x = 0;

y = 0;

width = 960;

height = 1200;

 

}

}

 

 

UIMainView = Viewports.Center

 

--[[

also you can use "displays" table to perfectly match you configuration .

it is generated by DCS automatically.

displays table is contains information about all currently attached displays

 

for example my setup is :

 

displays =

{

[1] =

{

x = 0, -- note : x == 0 and y == 0 is always mark primary windows display

y = 0,

width = 2560,

height = 1440

},

[2] =

{

x = -1920, -- mark that secondary display is on left side of primary display

y = 0,

width = 1920,

height = 1200

},

... for all displays

}

 

screen table also contain x, y members which mark top left corner of DCS window

 

note about fullscreen : directx doesn't allow fullscreen applications with resolutions more than primary display can handle,

so multimonitor presets in DCS will fall back to windowed mode if fullscreen initialization failed ( this info also will be printed to dcs.log)

 

for reconfigure viewports setup for each unit type independently you can declare here function

 

function reconfigure_for_unit(unit_type) --unit type is string with unit name

if unit_type == "A-10C" then

 

Viewports = ... define new Viewports table

-- also you can define cockpit displays viewports here

RIGHT_MFCD = ... define new RIGHT_MFCD viewport

 

else

Viewports = ... define default for others

RIGHT_MFCD = nil -- remove for others

end

end

 

--]]

[sIGPIC][/sIGPIC]

i7 9700k | 32gb DDR4 | Geforce 2080ti | TrackIR 5 | Rift S | HOTAS WARTHOG | CH PRO Pedals

Link to comment
Share on other sites

  • Recently Browsing   0 members

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