monitors DAT confusion

I am trying to uniquely identify what screen/projector is connected to an output.
This information should be in the EDID.

In Windows 10 It is possible to get the monitor’s serial number using the WMI utility
see this example:
activexperts.com/admin/scri … thon/0073/

The monitors Dat orders its “index” based on X/Left position of the display arrangement. The windows display manager index ordering shows a completely different index order and seems arbitrary.

https://www.derivative.ca/Forum/viewtopic.php?f=27&t=6502&p=24777&hilit=monitors+dat#p24777

But I think it is in the order it was plugged in. WMI orders its list of displays in the same order, but it doesn’t reveal an “index” variable or a screen position, just a unique display name.

Where is the “name” column in the Monitors Dat coming from in the system level? how come WMI comes up with a very different name? Any way to identify what display WMI is referring to in the Monitors Dat list?

how can I connect the data I am finding with WMI to the spacial coordinates shown in the Monitors DAT? I can’t figure out how to get screen position from WMI or I would use that as a way to identity each display.

chanOrder-windows.PNG

ChanOrder-TD.PNG

ChanOrder-WMI.PNG

ok, it seems that Touchdesigner uses the win32api to request monitorInfo

import win32api
monitors = win32api.EnumDisplayMonitors()
win32api.GetMonitorInfo(monitors[0][0])

     
win32api.GetMonitorInfo(monitors[1][0])

responds with
{‘Device’: ‘\\.\DISPLAY1’, ‘Work’: (0, 0, 1920, 1080), ‘Flags’: 1, ‘Monitor’: (0, 0, 1920, 1080)}
{‘Device’: ‘\\.\DISPLAY2’, ‘Work’: (1920, 0, 3360, 1080), ‘Flags’: 0, ‘Monitor’: (1920, 0, 3360, 1080)}

the question remains how can I confidently connect each display instance from this method to the serial numbers I am getting from WMI?

So it appears that the ordering of both the win32api and the results from WMI monitorID are both in the same order.

I am guessing that Touchdesigner is automatcally re-ordering them based on X position between parsing this value and displaying it in the Monitors DAT.

I was able to merge the two results and so far they match up every time, I will need to keep plugging in new screens in different orders to keep testing this.

I don’t know windows very well so I am sort of blind in the dark finding this out.
It would be SUPER COOL if the Monitors dat had some additional info about the connected displays. I will post my results soon.

I agree.

It seems like the automatic reordering of windows is great for casual use of the monitor DAT, but definitely is more difficult to use for permanent installations where you want to programmatically attach to things - things like reboots from windows updates can change this reported ordering, if I’m remembering a few past gigs of mine correctly.

Can you elaborate on how it makes things harder for permanent installations? We specifically did the automatic reordered because this way your monitor indices are consistent between reconnects, so when you say ‘Open a Window on monitor 0’, it’ll always open at the same spot on your desktop.
Without the automatic reordering your Window COMPs could end up anywhere after reconnects.

It’s fine if you want to re-order them by X, it just makes it harder for me to connect the serial numbers. Maybe you can just add this serial number info to the Monitors Dat?

This is a holy-grail technique I have been trying to figure out for years.

If it were possible to identify uniquely what display by serial number, you can define a configuration file that opens a specific tox/media for that output, regardless of its arrangement or whatever computer it was connected to. This essentially removes any windows arrangement adjustments needed.

A server rack of machines all with the same config file listing all possible serial numbers could be plugged in randomly to a bunch of projectors, a configuration file will uniquely identify each projector’s serial number and assigned TOX, we would know it’s position using monitors DAT.

Knowing uniquely what display is connected makes the system arrangement agnostic and allows for a high degree in system flexibility if any routing needs to change.

Historically I would build a config file that dictated what outputs I expected per machine and opened a perform window of that bound size. It would not know if those screens were in the correct order or if they were in the correct windows arrangement, this would require re-routing manually, virtually on the video switcher, in the config file or in windows display arrangement control panel.

This technique removes any need to re-arrange outputs ever, since the output EDID dictates what media TOX loads.