MCPcopy Create free account
hub / github.com/17cupsofcoffee/nova / texture

Method texture

src/graphics/batch.rs:167–179  ·  view source on GitHub ↗
(&mut self, texture: &Texture, position: Vec2, params: DrawParams)

Source from the content-addressed store, hash-verified

165 }
166
167 pub fn texture(&mut self, texture: &Texture, position: Vec2, params: DrawParams) {
168 self.push_sprite(
169 Some(texture),
170 Rectangle::new(0.0, 0.0, 1.0, 1.0),
171 Rectangle::new(
172 position.x,
173 position.y,
174 texture.width() as f32,
175 texture.height() as f32,
176 ),
177 params,
178 );
179 }
180
181 pub fn texture_region(
182 &mut self,

Callers 1

text_segmentsMethod · 0.45

Calls 3

push_spriteMethod · 0.80
widthMethod · 0.45
heightMethod · 0.45

Tested by

no test coverage detected