This example is running in WebGL2 and should work in most browsers. You can check the WebGPU examples here.
//! Shows how to render to a texture. Useful for mirrors, UI, or exporting images. use PI; use ; // Marks the first pass cube (rendered to a texture.) ; // Marks the main pass cube, to which the texture is applied. ; /// Rotates the inner cube (first pass) /// Rotates the outer cube (main pass)