Ejemplo n.º 1
0
	//Render the array of sprites.
	void Graphics::Update(float dt)
	{
		//Clear the backbuffer and fill it with the background color.
		//The first parameter is the number of rectangles you are going to clear--0 means clear the whole thing.
		//The second parameter is the array of rectangle to clear--just set it to NULL.
		//The third parameter says what to clear (in this case, the render target, but could be a zbuffer or stencil buffer).
		//The fourth parameter is the color to fill the target with.
		//The fifth and last parameters are the values to fill the zbuffer and stencil buffer with (if necessary).
		pDevice->Clear(0, NULL, D3DCLEAR_TARGET, D3DCOLOR_XRGB(0,0,0), 0.0f, 0);

		//Begin the scene
		if (SUCCEEDED(pDevice->BeginScene()))
		{
			DrawWorld( dt );

			DrawDebugInfo();

			//End the scene
			pDevice->EndScene();
		}
		
		//Present the backbuffer contents to the display.
		//The parameters are: source rect, dest rect, dest window (NULL meaning the default window), and dirty region.
		pDevice->Present(NULL, NULL, NULL, NULL);
	}
Ejemplo n.º 2
0
void DialogueTest::gameDraw()
{
    background->Draw();
    for(unsigned int i = 0; i < objects.size(); ++i)
        objects[i]->Draw();
    word->Draw();
    anima.UpAndDown();
    player->Draw();
    if(debug)
        DrawDebugInfo();
    
}
void CCodeCheckpointDebugMgr::Update(float dt)
{
	//Don't do any work if we haven't requested this as active
	if(!m_debug_ccoverage)
		return;

	m_timeSinceLastRun += dt;
	if( m_timeSinceLastRun > m_debug_ccoverage_rate)
	{
		UpdateRecords();
		m_timeSinceLastRun = 0;
	}

	DrawDebugInfo();

}