SFML community forums

Help => Graphics => Topic started by: heishe on June 23, 2009, 02:21:01 am

Title: sf::Sprite::SetSubRect has no effect
Post by: heishe on June 23, 2009, 02:21:01 am
following code still displays the whole sprite:

Code: [Select]

spr.SetSubRect(sf::IntRect(0,0,80,80);
window->Draw(spr);


why?
Title: sf::Sprite::SetSubRect has no effect
Post by: Laurent on June 23, 2009, 07:48:16 am
What is the size of the image? Can you show a complete (and short) source code that reproduces the problem?
Title: sf::Sprite::SetSubRect has no effect
Post by: heishe on June 24, 2009, 07:23:07 am
nevermind, coding at 4.50 am when your brain is not working properly probably isn't  that much of a good idea.