mirror of
https://github.com/SFML/SFML.git
synced 2025-02-18 06:18:01 +08:00
Fixed bug in View::Reset
git-svn-id: https://sfml.svn.sourceforge.net/svnroot/sfml/branches/sfml2@1510 4e206d99-4929-0410-ac5d-dfc041789085
This commit is contained in:
parent
fd483a9bf2
commit
7d68f59a5a
@ -126,8 +126,8 @@ void View::SetViewport(const FloatRect& viewport)
|
|||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
void View::Reset(const FloatRect& rectangle)
|
void View::Reset(const FloatRect& rectangle)
|
||||||
{
|
{
|
||||||
myCenter.x = (rectangle.Left + rectangle.Width) / 2.f;
|
myCenter.x = rectangle.Left + rectangle.Width / 2.f;
|
||||||
myCenter.y = (rectangle.Top + rectangle.Height) / 2.f;
|
myCenter.y = rectangle.Top + rectangle.Height / 2.f;
|
||||||
mySize.x = rectangle.Width;
|
mySize.x = rectangle.Width;
|
||||||
mySize.y = rectangle.Height;
|
mySize.y = rectangle.Height;
|
||||||
myRotation = 0;
|
myRotation = 0;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user