Small bug fix

Discussion area about developing or extending OGRE, adding plugins for it or building applications on it. No newbie questions please, use the Help forum for that.
rpgplayerrobin
Gnoll
Posts: 664
Joined: Wed Mar 18, 2009 3:03 am
x 371

Small bug fix

Post by rpgplayerrobin »

Hello!

This post is regarding Ogre 1.11.2 from repository.

I am not sure how to commit changes to Ogre without breaking something, so I figured I would just post it here in case anyone would want to fix it (I have already fixed it on my local version).
I tried committing it through the bitbucket.org website, but it just stayed at "Forking repository..." forever and never actually finishes.

The function "inline Corners getAllCorners(void) const" is doing one line incorrectly, which makes a huge difference:

Code: Select all

corners[0] = getCorner(FAR_LEFT_BOTTOM);
corners[1] = getCorner(FAR_LEFT_TOP);
corners[2] = getCorner(FAR_LEFT_TOP); <- THIS IS INCORRECT! IT SHOULD BE: FAR_RIGHT_TOP
corners[3] = getCorner(FAR_RIGHT_BOTTOM);

corners[4] = getCorner(NEAR_RIGHT_TOP);
corners[5] = getCorner(NEAR_LEFT_TOP);
corners[6] = getCorner(NEAR_LEFT_BOTTOM);
corners[7] = getCorner(NEAR_RIGHT_BOTTOM);
Here is a link to the file in the file in repository:
https://bitbucket.org/sinbad/ogre/src/3 ... ew-default
paroj
OGRE Team Member
OGRE Team Member
Posts: 2093
Joined: Sun Mar 30, 2014 2:51 pm
x 1129

Re: Small bug fix

Post by paroj »

nice catch! thanks.

changes to the 1.x branch should be commited via a pull-request at github:
https://github.com/OGRECave/ogre/pulls

there are checks in place that make sure that you do not break anything.
rpgplayerrobin
Gnoll
Posts: 664
Joined: Wed Mar 18, 2009 3:03 am
x 371

Re: Small bug fix

Post by rpgplayerrobin »

I think I finally managed to do that pull request now:
https://github.com/OGRECave/ogre/pulls