Skip to content

Commit

Permalink
more default depth buffer fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ncannasse committed May 14, 2018
1 parent 0360cf3 commit b5fb3c0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion h3d/impl/DirectXDriver.hx
Expand Up @@ -287,7 +287,7 @@ class DirectXDriver extends h3d.impl.Driver {
extraDepthInst = new h3d.mat.DepthBuffer(0, 0);
extraDepthInst.width = outputWidth;
extraDepthInst.height = outputHeight;
allocDepthBuffer(extraDepthInst);
extraDepthInst.b = allocDepthBuffer(extraDepthInst);
}
return extraDepthInst;
}
Expand Down
7 changes: 6 additions & 1 deletion h3d/impl/GlDriver.hx
Expand Up @@ -730,7 +730,12 @@ class GlDriver extends Driver {
override function getDefaultDepthBuffer() : h3d.mat.DepthBuffer {
if( defaultDepth != null )
return defaultDepth;
defaultDepth = new h3d.mat.DepthBuffer(bufferWidth, bufferHeight);
defaultDepth = new h3d.mat.DepthBuffer(0, 0);
@:privateAccess {
defaultDepth.width = this.bufferWidth;
defaultDepth.height = this.bufferHeight;
defaultDepth.b = allocDepthBuffer(defaultDepth);
}
return defaultDepth;
}

Expand Down

0 comments on commit b5fb3c0

Please sign in to comment.