Fullscreen GL on 6 screens?

I have an application (a simulator) where I need to bring up as many as 6 accelerated screens at once, one is for a 3d “out the window” view and the rest are for instrument panels.

The configuration will be using Windows XP, 3 dual-head NVIDIA GeForce cards (1AGP and 2PCI) and six seperate monitors.

Effectively, I want to setup each monitor as a seperate full-screen display and need some accelerated GL support on them all.

Does anyone know how to go about doing this? I have a pretty good idea how to do it with D3D but am not sure at all about how to do it with OpenGL.

I don’t have any problems with using windows-specific calls to setup the windows and rendering contexts, but I want the bulk of the code to be GL in case I want to port it over to a different OS later on.

Any help, particularly code samples, would be appreciated.

Good luck.
From my experience, you only get opengl acceleration on the ‘primary’ card (in your case, the AGP card). The other cards (PCI) will not be accelerated.
There was some talk from nvidia about sorting this out, but I really think it’s more down to microsoft to sort out - which ain’t gonna happen.

I’d say that you’ll have to use several computers to have acceleration on each of the 6 monitors. At least 2 computers if you’re using a card like the one made by matrox, which can render to 3 monitors at the same time.

But as your 5 secondary view will be “quite simple” - compared to the main view, maybe you’d better just program a software renderer for these views, and use OpenGL for the main one?

True that you can only get an accelerated OpenGL context for the primary adapter. You /may/ be able to get an accelerated context spanning both desktops of a dual-head nvidia card with some kind of effort.

As for the other four displays, my first thought is that you’re out of luck.

My /second/ thought is that you can get an accelerated context for the primary adapter, and that you can change the primary adapter through the desktop settings control without rebooting.

IF the existing context remains valid when taking ‘primary’ status away from a display, and if you can change which adapter is primary programmatically, then you might have options. If there is no API to change the primary adapter, then you might have to muck the registry to trick Windows.

Interesting line of thinking, anyway… Let me know if it pans out - you’ll probably have a chance to test it before I do.

– Jeff

I wouldn’t waste your time.
Not only have I tried everything in the past, but I’ve also seen this same thread crop up time and time again. Nobody, and I mean nobody has come up with a solution…go on, search the archives of this forum.
Yes, nvidias twin view works fine from a dual headed single card - you can have accelerated opengl across both screens ok, no problem, lovely. But that’s because as far as windows is concerned it’s one primary display.
The only solution I came up with for this problem was to use direct3d for the less important views. It sure ain’t purty, but it got the job done.

I thought NVidia said they would have a fix in their drivers by last summer (2002). Maybe it’s in their Quadro line?

Otherwise, if I was you, I would go for D3D. Software mode is ridiculous.

I guess there is indeed a real case when D3D is preferable to OpenGL.

I don’t know about full screen, but is it possible to get acceleration in a window on the non-primary monitors?

-Mezz

Simply switch to Linux and use XWindows with Xinerame - it can combine many hardware screens into one logical.

Originally posted by Mezz:
I don’t know about full screen, but is it possible to get acceleration in a window on the non-primary monitors?

Yes. There can be problems on some cards though if the window spans over two monitors.

I’ve been told by engineers at NVIDIA that, at least with their current cards and drivers this should be possible so long as the window is made on the target monitor and not made somewhere else and then moved.

However, I haven’t seen any sample that does it.

I originally wanted to do this project under Linux, but have had to move it to Windows because the drivers for many things I need simply don’t exist on Linux right now or aren’t well developed enough.

At this point, if GL can’t be made to work with 6 screens, I may have to go the DirectX route.

Now that I think about it, maybe a more productive question would be this…

If you were going to open full-screen OpenGL windows on 6 different monitors, how would you go about it?

Are the WindowsXP wgl calls the way to go, or should I be using DirectX calls to do it?

Sorry if at least part of this is a bit basic, most of the sample code I’ve grabbed (so far) uses GLUT which isn’t terribly helpful if you want to open windows on 6 different screens.

I can see two ways of trying it:

  1. create one big window covering the entire virtual desktop.
    Set pixel format, create context, and all that.
    With luck, if you use the same driver and card family for all three cards, this might just work.
    Then split your large window into 6 regions using viewport and/or scissoring.

  2. create one window that exactly matches the dimensions of each screen, making it borderless.
    Set pixel format for each window, create context for each window.
    Perhaps the Gods would smile upon you and this would give acceleration, too.

Please, report back what you find!

Originally posted by tfpsly:
I’d say that you’ll have to use several computers to have acceleration on each of the 6 monitors.

That’s how the Boeing F/A-18F simulator operates. It has a single (dual CPU) for the primary display & main simulation and a pc for each of the cockpit displays (4 per cockpit from memory - maybe 5 for the rear cockpit). Can’t say I noticed what the gfx cards were though…

Originally posted by rgpc:
That’s how the Boeing F/A-18F simulator operates. It has a single (dual CPU) for the primary display & main simulation and a pc for each of the cockpit displays

Interesting.How do they connect the pc’s with the main system?

[This message has been edited by roffe (edited 05-29-2003).]

Originally posted by roffe:
[BInteresting.How do they connect the pc’s with the main system?
[/b]

I didn’t even think to look at the networking setup (I suspect I would have only seen a cat5 disappearing into the wall somewhere).

Each machine was Win2k - I know this because the whole system froze when I had a turn and was approaching the carrier. And the primary pc was dual AMD2k+MP’s. It was quite a process to restart the machine but it looked like it could be done centrally. VNC or a simple switch box - I couldn’t see what was happening as the primary PC was behind me.

Made me want to setup one at home using Falcon (now if I could just get the source…)

Check out VT-CAVE and DIVERSE .

At the CAVE its not all work and research… they also have Quake and a few other games set up.

[This message has been edited by shinpaughp (edited 05-30-2003).]

Originally posted by roffe:
Interesting.How do they connect the pc’s with the main system?

Ethernet probably handles the data propagation, while genlocking keeps the swapbuffers in sync. Wildcats support genlocking (as well as various other pro cards). Probably uses the WGL_I3D_swap_frame_lock extension.

[This message has been edited by kieranatwork (edited 05-30-2003).]

Yep, but you don’t need genlock (or framelock) just for heads down displays. You can implement a few tricks to sync without genlock too on some cards, but it’s tricky.

100 BaseT would almost certainly be the networking of choice on a system like that but some people are using gigabit ethernet.

If you’re going to try something like this where you gang displays I’d suggest you investigate Open Producer:
http://www.andesengineering.com/Producer/

This is from the original author of Open Scene Graph. The videos on this page may inspire you, it shows the kind of rack based hardware setup he has at the end of the video:
http://www.andesengineering.com/old/products.html

You really want one of these to do a decent job though:
http://www.aechelon.com/products/pcnova/PCN5.htm

More info on the setup with operators console info etc:
http://www.aechelon.com/products/pcnova/PCN1.htm

I appreciate the ideas about using multiple computers, but this isn’t an option for my application. Using 6 computers (or even 3) would be too expensive and too difficult to maintain, not to mention it would take up a lot of space.

I’m starting to work on some test code but am having problems with the first step, that is, getting OpenGL windows open on each device.

I’ve done a lot of graphics code but I’m afraid I’m sufferning from not having written Microsoft Windows code for some time so I could use a little help getting going.

Essentially, what I’m stuck on is the proper way to enumerate all the monitors and then open a GL window on each one. Just figuring out which parts of the windows docs I should be reading is kind of tough. Is this something that can be done with GDI routines, wgl routines, direct X or some combination of them all?

Any help, particularly pointers to sample code that would apply, would be very helpful.