Link to home
Start Free TrialLog in
Avatar of pelegrin
pelegrin

asked on

Using 2 videCards with 2 monitors in NT 4.0

I have made two programs that will be running in the same machine showing diferent information. This machine is running under Windows NT 4.0, and it has two videocards and
two monitors. I have to show the videooutput of each program to each videocard. Is this posible???
How can I made it in Delphi?
Thanks in advance, and sorry but I'm from Spain and my English is note very good... :(
Avatar of BlackMan
BlackMan

There is native support for it in D4, what version are you using?
Take a look at the Microsoft Knowledge Base - DISPLAY.TXT file information : http://support.microsoft.com/support/kb/articles/q188/4/81.asp

As well as "ARTICLE-ID: Q179602 TITLE : How to Enable Multiple Display Support Using Windows 98" : http://support.microsoft.com/support/kb/articles/q182/7/08.asp

I know it's Windows 98 articles - but from there you could perhaps find more info on NT using multiple monitors.

Hope this helps
CyberSoft

Avatar of pelegrin

ASKER

I need info about NT and multiple monitors and the posibility of doing it with Delphi and  the info you gave me it's about only Windows 98.

What Delphi version are you using??
I'm using Delphi 3.0, but If the solution is Delphi 4.0 I will use Delphi 4.0. I expect that the programs made with D3 will work fine in D4... :)
I have visited Borland's page and I found that D4 can use the multiple monitor capabilites of Windows 98, but what happends with NT 4.0?? It's posible??
Perhaps NT 4 doesn't support multiple monitors yet - have you looked through the KB on Microsoft's site under NT? Perhaps have a reference there.

Sorry can't help you further
Don't worry, I will test it with Delphi 4.0 and perphaps it will work. In a few days I will post
a comment with a solution... :)
NT 4 does NOT have native suppport for multiple monitors.  That is to say there are no native API calls that deal with multiple monitors.  If your machine has more than one monitor, it is because your video card manufacturer created custom drivers to enable this feature.  I would be willing to bet you have either 2 Matrox Millinuem or 2 #9 Imagine 128 cards (as these are the only common Vid Card makers that offer dual monitor support with their cards that I know of).  Now that that is cleared up I would like more info as to what you want to do.  Under NT, if you have 2 monitors, say each running at 800x600, then you would just create 2 windows that are 800x600 and place them in each display.  Is that what you are trying to do.  I dont understand what the problem is.

Heath
BTW - Delphi 4 wont do you any good - the support is has only functions under 98

Heath
The problem is, how can I place the video-output of each program in a video-card?
I want to do it from my program, not from the video-card's software.
is it posible?
I am guessing here, as I dont actually have the hardware you are working with, but you should be able to do something like this.

place a button and and edit box on a form.  On the onclick event of the button do this

Edit1.Text := IntToStr(GetSystemMetrics(SM_CXSCREEN)) + ' ' + IntToStr(Screen.Width);

Does this give you the screen width of just one screen or both?  
Are both values the same?  If not you need to use the API call in your code.  If they are the same you can use the Delphi call.
I am guessing it will give you both the same (both monitors).  Assuming that you would do something like this in you two forms create event:

  Form1.Left := 0;
  Form1.Width := Screen.Width div 2;
  Form1.Top := 0;
  Form1.Height := Screen.Height;

for the other form:

  Form2.Left := Screen.Width div 2;
  Form2.Width := Screen.Width div 2;
  Form2.Top := 0;
  Form2.Height := Screen.Height;

This can be written much better, but should do what you are asking.  Is this what you wanted?  Please let us know

Heath  
BTW - The previous comment is assuming the screen is divided horizontally, not vertically, but I have never seen one done vertically before.  Maybe I should clarify further.  My guess is that as far as the system is concerned you only have ONE display, it is just drawing it across both monitors.  That is more or less how it works in Windows 98, except they have some fucntions to deal with centering dialogs and such. Anyway, you arent displaying anything to different cards, you are dispaying 2 images on ONE display, it is just being shown on 2 monitors.  I hope this helps to clarify things.

Heath
ASKER CERTIFIED SOLUTION
Avatar of cqhall
cqhall

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial