MCPcopy Create free account
hub / github.com/Bloom-Engine/engine / load_render_texture

Method load_render_texture

native/shared/src/textures.rs:43–47  ·  view source on GitHub ↗

Q1: Create a render texture. Returns a handle. The actual wgpu texture is created by the calling FFI function which has access to the Renderer.

(&mut self, width: u32, height: u32)

Source from the content-addressed store, hash-verified

41 /// Q1: Create a render texture. Returns a handle. The actual wgpu texture
42 /// is created by the calling FFI function which has access to the Renderer.
43 pub fn load_render_texture(&mut self, width: u32, height: u32) -> f64 {
44 self.render_textures.alloc(RenderTextureData {
45 width, height, texture_handle: 0.0,
46 })
47 }
48
49 /// Set the texture handle for a render texture (called after GPU creation).
50 pub fn set_render_texture_handle(&mut self, rt_handle: f64, tex_handle: f64) {

Callers 7

Calls 1

allocMethod · 0.80

Tested by

no test coverage detected