Author Topic: King's Quest: Mask of Eternity in stereoscopic 3D and ultra-high resolution  (Read 9516 times)

Offline Matthew1987

  • Wizard's Slave
  • *
  • Posts: 13
A few weeks ago, I downloaded the source code for the open source Glide wrapper OpenGlide and started working with it.

Although my primary intention was, at first, to see if I could get it to compile, I had another intention:

Adding the ability for it to render in stereoscopic 3D (in the same way that the stereo drivers by iZ3D and Tridef do).

Within just a few days, I was able to do that.  I tried it with Space Haste, and it worked perfectly.

I then tried it with King's Quest: Mask of Eternity.  It worked, although there are technical issues that you have to deal with, which are related to OpenGlide, not the 3D.  (In fact, because of how poorly written KQ8's game engine is, most Glide wrappers don't work with KQ8 at all.)

Another feature that I added is resolution overriding.  This allows you to, for example, play KQ8 in 1440x1080 resolution. :)

Here are some screenshots of KQ8 in stereoscopic 3D with this wrapper:

http://mbarich.tripod.com/kq8s1.jpg

http://mbarich.tripod.com/kq8s2.jpg

To view these screenshots in 3D, cross your eyes.  This is just for preview purposes; for a good effect, you need a 3D display.  I have a 3D monitor that uses circularly polarized glasses and row interleaving, so I can play it in 3D using the row interleaved modes I've added.

Since this modification of OpenGlide is only a prototype, I've only added support for cross-view and row interleaved modes.  I'm planning that soon I'll make a full-featured modification with more modes.

If any of you are interested in trying this out, here it is (make sure that you read the readme file):

http://mbarich.tripod.com/stereoglide.zip

As much as I enjoy bashing KQ8, I have to admit that it's incredible in stereoscopic 3D. :)
« Last Edit: January 25, 2012, 01:41:25 PM by Matthew1987 »

Offline Lambonius

  • Magical Genie
  • *******
  • Posts: 1839
  • Gender: Male
  • You wanna talk to God? Let's go see him together.
Awesome!  Can you post a link to one of those ultra-high resolution shots?

Offline snabbott

  • Beta Tester
  • Global Moderator
  • Phoenix Groupie
  • *****
  • Posts: 5241
  • Gender: Male
  • Fairy tales do come true!
Wow - that's very cool!
Royal alchemist to Queene Deloria :scholar:

Steve Abbott | Beta Tester | The Silver Lining

Offline Matthew1987

  • Wizard's Slave
  • *
  • Posts: 13
Here is a non-stereoscopic screenshot in 1440x1080 resolution:

http://mbarich.tripod.com/kq8hrs1.jpg

And here is an anaglyph stereoscopic screenshot, which can be viewed in 3D with red/cyan glasses:

http://mbarich.tripod.com/kq8s3.jpg

EDIT: I have now updated it to add support for checkerboard interleaved anaglyph and replaced the anaglyph screenshot with another one, which is rendered as a 1440x1080 checkerboard interleaved anaglyph.  I have also reduced the default ScreenShift setting from 96 to 64.
« Last Edit: January 27, 2012, 02:57:20 AM by Matthew1987 »

Offline MusicallyInspired

  • Powerful Wizard
  • ******
  • Posts: 955
  • Gender: Male
    • BrandonBlume.com - Freelance Music Services
It's neat, but MAN is the FOV high! Unrealistically so. Not the actual image but the 3D representation of it. It's like the "eyes" are too far apart or something.

Offline DawsonJ

  • Great Oracle
  • *****
  • Posts: 689
  • Gender: Male
Does that require a special graphics card? Not just the 3D, but the wrapper software itself.

Offline Matthew1987

  • Wizard's Slave
  • *
  • Posts: 13
Quote
It's neat, but MAN is the FOV high! Unrealistically so. Not the actual image but the 3D representation of it. It's like the "eyes" are too far apart or something.

Thanks for telling me about this.

There are actually two stereoscopic parameters: camera separation and screen separation.  Camera separation is the distance between the left and right eye cameras, and screen separation is the physical distance between the left and right eye images on the screen being used to view the content.  Because of this, the optimal screen separation varies depending on the particular display being used to view the content.

The screen separation should always be such that, with the left eye image on the left and the right eye image on the right, the physical distance between the left and right eye images of an object at virtually infinite distance (for example, a cloud) is as close to about 6 cm as possible.  But the number of pixels for this varies depending on the particular display.

With my 3D monitor, the optimal screen separation, in the native resolution, is around 192 pixels.  But with other displays, it may be higher or lower (more likely lower).

I have now changed the default screen separation to 128 pixels.  Both CameraShift and ScreenShift are "shift" values, which means that the default ScreenShift value is 64, since both eyes are shifted.

I have also added support for anaglyph rendering.  Because of problems resulting from clearing the depth buffer, I haven't been able to get full resolution stereoscopic rendering to work, so the anaglyph mode uses checkerboard interleaving.

In KQ8 there is a bug in that mode where the cursor trails, but that bug does not occur in any of the other modes.

I have replaced the original anaglyph screenshot I uploaded with another one, which is rendered as a 1440x1080 checkerboard interleaved anaglyph.  Here it is:

http://mbarich.tripod.com/kq8s3.jpg



Quote
Does that require a special graphics card? Not just the 3D, but the wrapper software itself.

Not at all.  It's not a driver, just a wrapper.  It translates Glide 2 calls into OpenGL.

It's just like the original version of OpenGlide, except that it has support for stereoscopic rendering and resolution overriding (and has a few other things improved).

For the best effect, you need a 3D display, but you can also use red/cyan glasses, or use the side-by-side mode and cross your eyes.

Make sure you read the readme, though; there are a few technical issues that you have to deal with when using OpenGlide with KQ8 (again, because of how poorly written KQ8's game engine is, most Glide wrappers don't even work with KQ8 at all).  As the readme explains, you have to use windowed mode, not full-screen, and there's an obscuring window that you can't get rid of while KQ8 is running and have to move the game window away from.

I'm actually surprised by how well the 3D works with KQ8.  Because of how poorly written KQ8's graphics engine is, I suspected that it wouldn't work well, but it works perfectly, as far as the 3D itself is concerned.

As with 3D in general, if you use a 3D display, and the settings are configured right, the effect is so lifelike that it feels like your display is a window into the actual scene. :)

And it's a LOT better than most of the 3D movies released so far.  Most filmmakers haven't figured out how to do 3D properly yet; the 3D in most of the recently released 3D movies has been a joke.  Two exceptions are Final Destination 5 and Hugo, but even those are only good some of the time.  (I will admit, however, that the early bridge collapse sequence, and the incredibly unexpected ending, of Final Destination 5 both were stunning in 3D and really have had an impact on me. :))

But when you play games in 3D with a stereoscopic driver or wrapper, you can just the stereoscopic parameters yourself to the optimal values. :)
« Last Edit: January 27, 2012, 06:51:44 AM by Matthew1987 »

Offline DawsonJ

  • Great Oracle
  • *****
  • Posts: 689
  • Gender: Male
Will your full-featured release have non-3d mods, just for resolution overrides? Surpassing the native resolution(s) of the original game has been a dream for many here. Unfortunately, only the Russian version has 1024x768, and nothing higher. My MoE decompilation project only gave me some dialogue scripts and minor code, not enough to internally modify resolution options.

Offline Matthew1987

  • Wizard's Slave
  • *
  • Posts: 13
Quote
Will your full-featured release have non-3d mods, just for resolution overrides? Surpassing the native resolution(s) of the original game has been a dream for many here. Unfortunately, only the Russian version has 1024x768, and nothing higher. My MoE decompilation project only gave me some dialogue scripts and minor code, not enough to internally modify resolution options.

Yes, and the prototype version does as well.  Just set StereoMode to 0, if that's what you want.

In case you didn't notice this, I posted a non-stereoscopic 1440x1080 screenshot earlier.  Here it is again:

http://mbarich.tripod.com/kq8hrs1.jpg



If you want to play KQ8 in ultra-high resolution right now, just do the following:

1.  Download http://mbarich.tripod.com/stereoglide.zip and unzip it into KQ8's root folder (the same folder as "Mask.exe").  Make sure that this doesn't conflict with any existing Glide wrappers.

2.  Create a file in KQ8's root folder named "OpenGLid.ini".  Copy and paste the following into that file:

Code: [Select]
Configuration File for OpenGLide

Info:
Priority goes from 0(HIGH) to 5(IDLE)
Texture Memory goes from 2 to 32
Frame Buffer Memory goes from 2 to 16

Version=0.09rc9

[Options]
WrapperPriority=2
StereoMode=0
ScreenShift=64
CameraShift=32768
Resolution=1080
CreateWindow=1
InitFullScreen=0
EnableMipMaps=0
IgnorePaletteChange=0
Wrap565to5551=0
EnablePrecisionFix=1
EnableMultiTextureEXT=1
EnablePaletteEXT=1
EnableVertexArrayEXT=0
TextureMemorySize=4
FrameBufferMemorySize=4
NoSplash=1

3.  With your display in it's native resolution, run "Mask.exe" and it should work.  As I said earlier, you have to run it in windowed mode, not full screen, and there will be an obscuring window that you can't get rid of and have to move the game window away from.  The obscuring window is the size of KQ8's selected resolution, so to make it as small as possible, set KQ8's resolution setting (which will be overriden for the game window) to the smallest resolution KQ8 allows (640x480).  Make sure that KQ8 is in 3Dfx mode, of course.

Once you've started KQ8, move the game window away from the obscuring window, to whatever position allows for the best view.  You may have to leave some of it clipped, but the higher resolution is worth it.

If the game doesn't allow you to get the cursor outside the game window, try using CTRL + ALT + DEL to bring up the task manager.  If that doesn't work, try other things (like moving it right when the game starts).  There are various ways.

For the mouse to work, the obscuring window will have to be selected, not the game window.

Unfortunately, I haven't been able to find any way of getting rid of that obscuring window.  But if you have the game window moved out of the way, or to where as little of it is clipped as possible, it's good enough.

If you want to run in a resolution other than 1440x1080, set "Resolution" to the height of the resolution that you want.  Both the height and the resulting width must be even numbers.



There really was no excuse for KQ8 to have such limited resolution options.  Since DirectX, OpenGL, and Glide use viewport projection, all that's necessary to render at a different resolution is to change the size of the viewport.

I have always been struck by how rushed KQ8 was.  When it was released, it's Direct3D support was a joke.  And to this day, not all the features are supported.

And, of course, in the manuel, it specifically says for each feature that it is supported in both Direct3D and 3Dfx modes.

I never knew that the Russian version had additional options.  Did it support all the features in Direct3D mode?  And did it support 1024x768 in Direct3D mode, or just 3Dfx?
« Last Edit: February 01, 2012, 03:27:44 AM by Matthew1987 »

Offline DawsonJ

  • Great Oracle
  • *****
  • Posts: 689
  • Gender: Male
Cool! Thanks for the instructions! I'll be ordering a new graphics card this Saturday, so I'll wait until that arrives to try the game on a respectable card. :)

As far as the details of the Russian version are concerned, all I've seen is a screenshot somebody linked in one of the MoE threads on this forum.

Due to its format, MoE has been the source of many arguments and threads here, so the screenshot will be difficult to chase down.

Offline dark-daventry

  • Phoenix Groupie
  • **********
  • Posts: 5229
  • Gender: Male
  • Nothing is true, everything is permitted
Re: King's Quest: Mask of Eternity in stereoscopic 3D and ultra-high resolution
« Reply #10 on: February 10, 2012, 07:49:49 PM »
This is truly awesome; I may just have to give this a shot sometime, though I may wait for a final release. When it comes to betas, I generally only like to test out things like Web Browsers. Otherwise I try to stick to final or near-final releases. Still, this is intriguing and something I will be keeping a close eye on!
Founder of the (new) Left Handed Alliance Of Left Handed People (LHALHP)

Gay and proud of it!

Avid Adventure Game fan

Offline Aroenai

  • Wizard's Slave
  • *
  • Posts: 2
Unfortunately, only the Russian version has 1024x768, and nothing higher.

It doesn't. In fact, I haven't seen any compelling evidence to suggest that the Russian version isn't just a hacked pirate copy of the English version.

1024x768 would have been really expensive to do at the time, the Voodoo 2 only supported it when you had two cards running in SLI mode (different than Nvidia's implementation today). The max resolution for a single Voodoo 2 was 800x600.

Offline DawsonJ

  • Great Oracle
  • *****
  • Posts: 689
  • Gender: Male
Unfortunately, only the Russian version has 1024x768, and nothing higher.

It doesn't. In fact, I haven't seen any compelling evidence to suggest that the Russian version isn't just a hacked pirate copy of the English version.

1024x768 would have been really expensive to do at the time, the Voodoo 2 only supported it when you had two cards running in SLI mode (different than Nvidia's implementation today). The max resolution for a single Voodoo 2 was 800x600.

Somewhere around here on the forum, there is (or was) a link to an in-game screenshot which showed a higher display option in MoE's settings.

Offline Aroenai

  • Wizard's Slave
  • *
  • Posts: 2
I think I found what you're talking about, but there's no screenshot. It's a link to a Russian forum with text that mentions 1024x768.

Everything I've found suggests that there was no official Russian release, and that the Russian version that's out there is a pirate translation.

Offline DawsonJ

  • Great Oracle
  • *****
  • Posts: 689
  • Gender: Male
I could be wrong. I'm not sure which languages were offered for Sierra's games. In fact, I just learned of a German version of KQVII - with a complete written and voiced translation (minus the song, which is still in English).

Quite a few games are receiving fan translations. Since the text is easy enough to find within the game's files, it doesn't surprise me that MoE has a fan-patched version in Russian.
« Last Edit: April 20, 2012, 03:08:05 AM by DawsonJ »