I think i found a camera bug, please confirm.
When i create more than one camera, the oDBCamera.SetCurrentCamera doesnt work.
Heres a sample i quickly threw together:
static void Main()
{
//Initializes and opens the renderer.
if (!InitializeDGDK("30820120300d06092a864886f70d01010105000382010d00308201080282010100b4a39d67bde0b0880fddaee8f407f77d59aca834113d0251191f8168d4a32b965e434e2870e58353441a9589883dfd70eee9a71a00bddd7262e9b7abcf804e2a1e05a67354f064ff8e9f42144cb2a59238ddce28e89e0545f7ab6c9f483be9a16f0fb7898ffb2995e86215ed3db6fa19db338b8b2e2226cb1ca62fa5583673e44377cb74010822598bfcb039def70b8984fa1d2a95ab2eb2fd4ab08fe35b8f166155390bbfb7e7c43d6c852e9820b89a429b23bfe8d20814f0c71c5f18f6a9ebdfda9dd689dee2824c375997ec268188b695ce4f7aade7f4b05830b42d1279211e393718dd80f1980689e4e947375bdf1bf5ff849180b10b0fe4b81eccd33191020111")) return;
oDBDisplay.SetWindowTitle("SetCamera");
oDBDisplay.SetDisplayMode(1024, 768, 32);
oDBCore.SyncOn(); oDBCore.SyncRate(0);
oDBCamera.AutoCamOff();
oDBCamera.MakeCamera(1);
oDBCamera.PositionCameraC(0, 0, 0, -100);
oDBCamera.PointCameraB(0,0,0,0);
oDBCamera.PositionCameraC(1, 1000, 1000, 900);
oDBCamera.PointCameraB(1, 1000, 1000, 1000);
oDB3D.MakeObjectCube(1, 20);
oDB3D.PositionObject(1, 0, 0, 0);
oDB3D.ColorObject(1, oDB2D.RGBC(255, 0, 0));
oDB3D.MakeObjectSphereB(2, 20);
oDB3D.PositionObject(2, 1000, 1000, 1000);
oDB3D.ColorObject(2, oDB2D.RGBC(0, 255, 0));
oDBCamera.SetCurrentCamera(0);
//Uncomment these two line to see that they exist
//oDBCamera.SetCameraViewB(0, 0, 0, 512, 384);
//oDBCamera.SetCameraViewB(1, 512, 384, 1024, 768);
bool _keypress = false;
int _currentCam = 0;
while (oDBP.LoopGDK)
{
if (!_keypress)
{
if (oDBInput.SpaceKey() > 0)
{
_keypress = true;
}
}
else if (oDBInput.ScanCode() == 0)
{
_keypress = false;
if (_currentCam == 0)
_currentCam = 1;
else
_currentCam = 0;
oDBCamera.SetCurrentCamera(_currentCam);
}
oDBDisplay.SetWindowTitle(_currentCam.ToString());
oDBCore.Sync();
}
}
Press spacekey to switch between the 2 cameras (which doesnt switch).
Proud member of The Unforgiven Warriors
http://www.tuwguild.com