Skip to content

Commit

Permalink
Update split_screen example
Browse files Browse the repository at this point in the history
  • Loading branch information
luboslenco committed Jul 19, 2019
1 parent 28f5e32 commit bff90ee
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions split_screen/Sources/arm/SplitScreen.hx
Original file line number Diff line number Diff line change
Expand Up @@ -28,11 +28,13 @@ class SplitScreen extends iron.Trait {
var g = RenderPathCreator.path.currentG;

// Left viewport
RenderPathCreator.setTargetMeshes();
Scene.active.camera = cam1;
g.viewport(0, 0, w, h);
drawMeshes();

// Right viewport
RenderPathCreator.setTargetMeshes();
Scene.active.camera = cam2;
g.viewport(w, 0, w, h);
drawMeshes();
Expand Down

0 comments on commit bff90ee

Please sign in to comment.