The Dragon King
Display File Setup 
About Mame Hooker Overview:

Did you know that MameHooker can be used to manage a secondary monitor? Did you know that it can display special output-controlled "display files" on a secondary monitor? Well it can, and it is a very useful function, but before you begin to use it, we need to go over a little bit of monitor theory.

First, let us look at the extremely confusing looking image below:

Don't be overwhealmed, it's just going to be used as a visual reference. If you have multiple monitors hooked up in windows, and you go to the display options in the windows control panel (exact name varies by windows version) you are actually going to see something very similar to the graphic shown above. Your main display (primary monitor) will be in the center, usually with a big "1" on it and any additional monitors will be arranged around it. Why do we care? Well mamehooker, as well as earlier versions of windows, renders graphics to a secondary monitor by using size and positional values based on the primary and secondary monitors resolutions and positions.

Take a look at our primary monitor #1. Note that it's resolution is 640x480 in this example. Any secondary monitors placed to the right or below monitor #1 have their position (always the upper-left corner of said monitor) determined by the resolution of monitor #1. It is for this reson that you should avoid placing your secondary monitor in positions of #4 and #5. Why? Well your mame/emulator setup might use multiple resolutions. If it does then mamehooker is going to have a hard time figuring out where the secondary monitor should be rendered.

Your two best positions are #2, and #3, their positions are dependant upon the resolutions of your extra monitor. This resolution shouldn't change so it is fairly stable and thus easier to deal with.

Now that you have chosen a postion (hopefully #2 or #3) you'll want to move it there. You can do this in the windows control panel by simply dragging the icon for the monitor where you want it. Be sure you line up the corners!!

We should probably get mamehooker setup for using display files at this point. In your mamehooker folder, go to the displays folder and open up "default.dis" in notepad.

It should look something like this:

[Layout]
x=0
y=0
width=800
height=600

Fairly simple right, we simply tell mamehooker the resolution of the display and it's positon. Let's use monitor #2 as an example. You always want to fill out the resolution first, as that part is easy and our resolution is 320x240 so...

[Layout]
x=0
y=0
width=320
height=240

Now we have to think about where the monitor is in relation to the main monitor. In our case monitor #2 is vertically aligned with monitor #1, so we can leave the y value at 0. Horizontally, the monitor is to the left of monitor #1, so we take the width of moitor #2 and subtract it from the x positon of monitor #1 (which is ALWAYS 0).

So our finished dis file looks like this:

[Layout]
x=-320
y=0
width=320
height=240

Easy once you get the hang of it right? No??... well read it again until you get it.

Once you do read some other display file tutorials to see all the cool things display files can do.