Page 1 of 1

Letterbox? (UPDATED)

Posted: Tue Oct 03, 2006 11:53 pm
by afharris_83
Hi all!

I'm just getting started with Irrlicht in C#; so far I've got a decent mock-up of a first-person shooter with a little environmental stuff going on (snow, rain, etc.)

What I'm interested in doing is twofold: a) I'd like to be able to switch to gray-scale for some cinematic moments, and b) reduce the viewport to letterbox (black bars at the top and bottom of the screen.)

Any thoughts?

UPDATED

I thought I'd post the solution I arrived at for one of my two questions in case anybody else tried the same thing. It turned out to be really simple, once I thought about it...::sigh::

For the widescreen, I wrote the following:

...

// hardcoded resolution only temporary
driver.ViewPort = new Rect(new Position2D( 0, 0 ), new Position2D( 1024, 768 ));

// set black background
device.VideoDriver.BeginScene(true, true, new Color( 0, 0, 0, 0 ));

// resize to widescreen
driver.ViewPort = new Rect(new Position2D( 0, 68 ), new Position2D( 1024, 700 ));

device.SceneManager.DrawAll();

...

Still working on the gray-scale thing...probably night vision as well.