SDLPP: add function to change texture while keeping SRC rect
This commit is contained in:
@@ -78,6 +78,9 @@ void RenderObject::setTexture( const std::shared_ptr< Texture > &t,
|
||||
texture = t;
|
||||
src_rect = source_rect;
|
||||
}
|
||||
void RenderObject::setTextureKeepSRC( const std::shared_ptr< Texture > &t ) {
|
||||
setTexture(t, src_rect);
|
||||
}
|
||||
void RenderObject::setTexture( const std::shared_ptr< Texture > &t,
|
||||
int source_x, int source_y, int source_width,
|
||||
int source_height ) {
|
||||
|
||||
Reference in New Issue
Block a user