Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - chaosblasta

Pages: [1]
1
Graphics / Re: Possible Rect<T>.contains() bug?
« on: June 09, 2017, 03:04:06 pm »
I see now. Thank you for the quick responses!

2
Graphics / Possible Rect<T>.contains() bug?
« on: June 09, 2017, 01:53:13 pm »
According to documentation, the contains() function is non-inclusive and therefore will return false if the point is located on the edge of the rectangle. This isn't really the case on my tests though..

So with

sf::IntRect rect = {0,0,3,3};
sf::Vector2i point = {0,0};

rect.contains(point) returns true. In fact, every point from (0,0) (2,2) returns true, even though in theory only (1,1) should be true. I may not be understanding the documentation though, and I apologize if this is a mistake on my part.

Pages: [1]