article thumbnail

Shader array properties

Cocos

stringwizard5: If you use the material.setProperty function, one of the possible arguments that it can take is render pass I am not quite sure what do you mean. We are currently using this shader to create dynamic light effect on 2d sprites, so we are updating it very often. First of all declare your array on the shader.

Shaders 40
article thumbnail

Cocos Creator 3.8 Post-Process Shader Writing (2/2) Advanced

Cocos

Preface In the last article , Kylin shared how to add your own post-effect Shader in the custom render pipeline in Cocos Creator 3.8. However, based on the BlitScreen solution, we can only write the simplest post-effect Shader. Today Kylin will use Gaussian blur to demonstrate how to write a multi-pass post-effect shader.

Shaders 98
Insiders

Sign Up for our Newsletter

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Trending Sources

article thumbnail

Differentiable Slang: A Shading Language for Renderers That Learn

Nvidia

Fast, Modular and Differentiable Shader Programming. Fast, Modular and Differentiable Shader Programming. The paper shows how a single language can serve as a unified platform for real-time, inverse, and differentiable rendering. Build differentiable renderers from existing graphics code.

Render 52
article thumbnail

Cocos Shader Tutorial 1.0 - about UV

Cocos

The vertical axes of textures and picture pixels is shown above, when sampling textures in shaders, that is from top to bottom, which is top-right corner. This is consistent with how most image file formats store pixel data, and with how most graphics APIs work (including DirectX, Vulkan, Metal, WebGPU, but not OpenGL). x,waveFactor.y-uv0.y);

Shaders 98
article thumbnail

Improve Shader Performance and In-Game Frame Rates with Shader Execution Reordering 

Nvidia

NVIDIA recently introduced a new feature available in the next generation of GPUs: Shader execution reordering (SER). NVIDIA recently introduced a new feature available in the next generation of GPUs: Shader execution reordering (SER). For more information, see the Shader Execution Reordering whitepaper.

article thumbnail

Cocos Creator 3.7.2 Focuses On Optimized Rendering And Lighting Capabilities

Cocos

This version optimizes some rendering and lighting capabilities, fixes a series of key issues recently reported by users, and recommends that all v3.x Engine • Added DebugView at runtime UI control rendering debugging function. Skip rendering when the UI element Opacity is 0. Skip rendering when the UI element Opacity is 0.

Render 52
article thumbnail

Practical Tips for Optimizing Ray Tracing

Nvidia

This starts from mesh instance selection and their data. This starts from mesh instance selection and their data processing towards optimized tracing and shading of every hit that you encounter. Instance data generation. It may be a good idea to perform static and dynamic object data processing in parallel on the CPU.