MCPcopy Create free account
hub / github.com/ObEngine/ObEngine / useTextureSize

Method useTextureSize

src/Core/Graphics/Sprite.cpp:49–55  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

47 }
48
49 void Sprite::useTextureSize()
50 {
51 const Transform::UnitVector textureSize = this->getTexture().getSize();
52 const Transform::UnitVector initialSpriteSize(
53 textureSize.x, textureSize.y, Transform::Units::ScenePixels);
54 this->setSize(initialSpriteSize);
55 }
56
57 void Sprite::draw(RenderTarget surface, const Transform::UnitVector& camera)
58 {

Callers 1

applyTextureMethod · 0.80

Calls 3

getSizeMethod · 0.45
getTextureMethod · 0.45
setSizeMethod · 0.45

Tested by

no test coverage detected