Exemplo n.º 1
0
 internal virtual void OnRender(GPUContext context)
 {
 }
Exemplo n.º 2
0
 /// <summary>
 /// Draws scene objects depth (to the output Z buffer). The output must be depth texture to write hardware depth to it.
 /// </summary>
 /// <param name="context">The GPU commands context to use.</param>
 /// <param name="task">Render task to use it's view description and the render buffers.</param>
 /// <param name="output">The output texture. Must be valid and created.</param>
 /// <param name="customActors">The custom set of actors to render. If empty, the loaded scenes will be rendered.</param>
 public static void DrawSceneDepth(GPUContext context, SceneRenderTask task, GPUTexture output, List <Actor> customActors)
 {
     Internal_DrawSceneDepth(FlaxEngine.Object.GetUnmanagedPtr(context), FlaxEngine.Object.GetUnmanagedPtr(task), FlaxEngine.Object.GetUnmanagedPtr(output), Utils.ExtractArrayFromList(customActors));
 }
Exemplo n.º 3
0
 /// <summary>
 /// Draws postFx material to the render target.
 /// </summary>
 /// <param name="context">The GPU commands context to use.</param>
 /// <param name="renderContext">The rendering context.</param>
 /// <param name="material">The material to render. It must be a post fx material.</param>
 /// <param name="output">The output texture. Must be valid and created.</param>
 /// <param name="input">The input texture. It's optional.</param>
 public static void DrawPostFxMaterial(GPUContext context, ref RenderContext renderContext, MaterialBase material, GPUTexture output, GPUTextureView input)
 {
     Internal_DrawPostFxMaterial(FlaxEngine.Object.GetUnmanagedPtr(context), ref renderContext, FlaxEngine.Object.GetUnmanagedPtr(material), FlaxEngine.Object.GetUnmanagedPtr(output), FlaxEngine.Object.GetUnmanagedPtr(input));
 }
Exemplo n.º 4
0
 /// <summary>
 /// Draws scene objects depth (to the output Z buffer). The output must be depth texture to write hardware depth to it.
 /// </summary>
 /// <param name="context">The GPU commands context to use.</param>
 /// <param name="task">Render task to use it's view description and the render buffers.</param>
 /// <param name="output">The output texture. Must be valid and created.</param>
 /// <param name="customActors">The custom set of actors to render. If empty, the loaded scenes will be rendered.</param>
 public static void DrawSceneDepth(GPUContext context, SceneRenderTask task, GPUTexture output, Actor[] customActors)
 {
     Internal_DrawSceneDepth(FlaxEngine.Object.GetUnmanagedPtr(context), FlaxEngine.Object.GetUnmanagedPtr(task), FlaxEngine.Object.GetUnmanagedPtr(output), customActors);
 }
Exemplo n.º 5
0
        public static void Draw(RenderTask task, IntPtr[] selectedActors, GPUTexture target = null, GPUContext context = null, GPUTexture depthBuffer = null, bool enableDepthTest = false)
        {
#if UNIT_TEST_COMPILANT
            throw new NotImplementedException("Unit tests, don't support methods calls. Only properties can be get or set.");
#else
            Internal_Draw(FlaxEngine.Object.GetUnmanagedPtr(task), selectedActors, FlaxEngine.Object.GetUnmanagedPtr(target), FlaxEngine.Object.GetUnmanagedPtr(context), FlaxEngine.Object.GetUnmanagedPtr(depthBuffer), enableDepthTest);
#endif
        }
Exemplo n.º 6
0
 internal override void OnRender(GPUContext context)
 {
     Render(context);
 }
Exemplo n.º 7
0
 /// <summary>
 /// Called when on rendering end.
 /// </summary>
 /// <param name="context">The GPU execution context.</param>
 protected virtual void OnEnd(GPUContext context)
 {
     End?.Invoke(this, context);
 }