Second camera looks squished
by USC Cinema #0021 · in Torque Game Builder · 04/15/2009 (12:39 pm) · 3 replies
I made two new camera with:
new t2dSceneWindow(sceneWindow2D) {
canSaveDynamicFields = "0";
isContainer = "0";
Profile = "GuiDefaultProfile";
HorizSizing = "width";
VertSizing = "height";
Position = "0 0";
Extent = "1024 768";
MinExtent = "8 8";
canSave = "1";
Visible = "1";
hovertime = "1000";
lockMouse = "0";
useWindowMouseEvents = "1";
useObjectMouseEvents = "1";
};
new t2dSceneWindow(sceneWindow2D2) {
canSaveDynamicFields = "0";
isContainer = "0";
Profile = "GuiDefaultProfile";
HorizSizing = "width";
VertSizing = "height";
Position = "0 0";
Extent = "512 768";
MinExtent = "8 8";
canSave = "1";
Visible = "1";
hovertime = "1000";
lockMouse = "0";
useWindowMouseEvents = "1";
useObjectMouseEvents = "1";
};You can see that my 2nd camera has a narrow extent because I want it that way. But the content looks quite squished. How can I get it to reveal a narrow area, but not squish the content?
#2
I don't quite understand how to adjust the camera to reflect a proper ratio? And as for names, I'm not totally sure, but isn't the name "sceneWindow2D" a unique name?
Thanks very much for your reply!
04/15/2009 (1:50 pm)
In fact they are not overlapping... In game.cs I used this line to add the 2nd camera, which works fine:sceneWindow2D2.setSceneGraph(sceneWindow2D.getSceneGraph());
I don't quite understand how to adjust the camera to reflect a proper ratio? And as for names, I'm not totally sure, but isn't the name "sceneWindow2D" a unique name?
Thanks very much for your reply!
#3
The ratio of width/height on the camera has to match the ratio of width/height on the scene or things will look distorted (like you are seeing). If you change the height, you have to change the width by the same multiplier, and vice versa, to prevent things looking distorted.
04/16/2009 (2:49 am)
What are you trying to do? Have a wide-screen effect camera?The ratio of width/height on the camera has to match the ratio of width/height on the scene or things will look distorted (like you are seeing). If you change the height, you have to change the width by the same multiplier, and vice versa, to prevent things looking distorted.
Torque 3D Owner Jason Ravencroft