Explorar o código

Bugfix: Fixing the getting started example

BearishSun %!s(int64=8) %!d(string=hai) anos
pai
achega
f88f0b8f86
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      Source/Examples/ExampleGettingStarted/Main.cpp

+ 1 - 1
Source/Examples/ExampleGettingStarted/Main.cpp

@@ -390,7 +390,7 @@ namespace bs
 
 
 		// First we want another camera that is responsible for rendering GUI
 		// First we want another camera that is responsible for rendering GUI
 		HCamera guiCamera = guiSO->addComponent<CCamera>();
 		HCamera guiCamera = guiSO->addComponent<CCamera>();
-		sceneCamera->getViewport()->setTarget(window);
+		guiCamera->getViewport()->setTarget(window);
 
 
 		// Notify the renderer that the camera will only be used for overlays (e.g. GUI) so it can optimize its usage
 		// Notify the renderer that the camera will only be used for overlays (e.g. GUI) so it can optimize its usage
 		SPtr<RenderSettings> settings = guiCamera->getRenderSettings();
 		SPtr<RenderSettings> settings = guiCamera->getRenderSettings();