SceneEncoder constructor
SceneEncoder(
- RenderTarget renderTarget,
- Camera _camera,
- Size dimensions,
- Environment _environment,
Implementation
SceneEncoder(gpu.RenderTarget renderTarget, this._camera, ui.Size dimensions,
this._environment) {
_cameraTransform = _camera.getViewTransform(dimensions);
_commandBuffer = gpu.gpuContext.createCommandBuffer();
_transientsBuffer = gpu.gpuContext.createHostBuffer();
// Begin the opaque render pass.
_renderPass = _commandBuffer.createRenderPass(renderTarget);
_renderPass.setDepthWriteEnable(true);
_renderPass.setColorBlendEnable(false);
_renderPass.setDepthCompareOperation(gpu.CompareFunction.lessEqual);
}