Exemplo n.º 1
0
void App::main() {

    window()->setCaption("Q3 Renderer");

	setDebugMode(true);
	debugController.setActive(true);

    dumpPolygons = false;
    clipMovement = true;

    sky = Sky::create(renderDevice, dataDir + "sky/");
    debugCamera.setNearPlaneZ(-0.5f);
    debugCamera.setFarPlaneZ(-100);//(float)-inf());
    debugController.init(renderDevice, userInput);
    debugController.setMoveRate(500 * BSPMAP::LOAD_SCALE);
    debugController.setActive(true);
	renderDevice->setColorClearValue(Color3(0.1f, 0.5f, 1.0f));
    // Load the map
    map = new BSPMAP::Map();
    bool ret = map->load("D:/games/dojo/scratch/data-files/q3/", "ut_ricochet.bsp");
//    bool ret = map->load("D:/media/models/q3/maps/urbanterror/", "ut_ricochet.bsp");
      
    debugAssert(ret); (void)ret;

    debugController.setPosition(map->getStartingPosition());
    debugController.lookAt(map->getStartingPosition() - Vector3::unitZ());
    debugCamera.setCoordinateFrame(debugController.getCoordinateFrame());
    
    applet->run();
}
Exemplo n.º 2
0
int main()
{
    initWindow(1024, 768, &Demo::resizeWindow);

    Demo app;
    app.run();
}
Exemplo n.º 3
0
void App::main() {
	setDebugMode(true);
	debugController->setActive(true);

    // Load objects here
    sky = Sky::fromFile(dataDir + "sky/");
    
    applet->run();
}
Exemplo n.º 4
0
void App::main() {
	setDebugMode(true);
	debugController->setActive(true);
    debugShowRenderingStats = true;

    debugController->setMouseMode(FirstPersonManipulator::MOUSE_DIRECT_RIGHT_BUTTON);

    // Load objects here
    sky = Sky::fromFile(dataDir + "sky/");
    
    applet->run();

}