@@ -1850,7 +1850,7 @@ int rect_testUnionFRect(void *arg)
1850
1850
* \sa
1851
1851
* http://wiki.libsdl.org/SDL2/SDL_EncloseFPoints
1852
1852
*/
1853
- int rect_testEncloseFPointsUnionFRect (void * arg )
1853
+ int rect_testEncloseFPoints (void * arg )
1854
1854
{
1855
1855
const struct {
1856
1856
SDL_bool with_clip ;
@@ -1919,8 +1919,8 @@ int rect_testIntersectFRectAndLine(void *arg)
1919
1919
SDL_FPoint expected1 ;
1920
1920
SDL_FPoint expected2 ;
1921
1921
} cases [] = {
1922
- { { 0 , 0 , 0 , 0 }, { -4.8f , -4.8f }, { 5.2f , 5.2f }, SDL_FALSE },
1923
- { { 0 , 0 , 2 , 2 }, { -1 , -1 }, { 3.5f , 3.5f }, SDL_TRUE , { 0 , 0 }, { 1 , 1 } },
1922
+ { { 0 , 0 , 0 , 0 }, { -4.8f , -4.8f }, { 5.2f , 5.2f }, SDL_FALSE },
1923
+ { { 0 , 0 , 2 , 2 }, { -1 , -1 }, { 3.5f , 3.5f }, SDL_TRUE , { 0 , 0 }, { 1 , 1 } },
1924
1924
{ { -4 , -4 , 14 , 14 }, { 8 , 22 }, { 8 , 33 }, SDL_FALSE }
1925
1925
1926
1926
};
@@ -1937,11 +1937,11 @@ int rect_testIntersectFRectAndLine(void *arg)
1937
1937
result = SDL_IntersectFRectAndLine (& cases [i ].rect , & p1 .x , & p1 .y , & p2 .x , & p2 .y );
1938
1938
SDLTest_AssertCheck (result == cases [i ].result , "Got %d, expected %d" , result , cases [i ].result );
1939
1939
if (cases [i ].result ) {
1940
- SDLTest_AssertCheck (IsFPointEqual (& p1 , & cases [i ].p1 ) && IsFPointEqual ( & p2 , & cases [ i ]. p2 ),
1940
+ SDLTest_AssertCheck (IsFPointEqual (& p1 , & cases [i ].expected1 ),
1941
1941
"Got p1={ %g, %g }, expected p1={ %g, %g }" ,
1942
1942
p1 .x , p1 .y ,
1943
1943
cases [i ].expected1 .x , cases [i ].expected1 .y );
1944
- SDLTest_AssertCheck (IsFPointEqual (& p1 , & cases [i ].p1 ),
1944
+ SDLTest_AssertCheck (IsFPointEqual (& p2 , & cases [i ].expected2 ),
1945
1945
"Got p2={ %g, %g }, expected p2={ %g, %g }" ,
1946
1946
p2 .x , p2 .y ,
1947
1947
cases [i ].expected2 .x , cases [i ].expected2 .y );
@@ -2093,19 +2093,19 @@ static const SDLTest_TestCaseReference rectTest32 = {
2093
2093
};
2094
2094
2095
2095
static const SDLTest_TestCaseReference rectTest33 = {
2096
- (SDLTest_TestCaseFp )rect_testIntersectFRect , "rect_IntersectFRect " , "Tests SDL_IntersectFRect" , TEST_ENABLED
2096
+ (SDLTest_TestCaseFp )rect_testIntersectFRect , "rect_testIntersectFRect " , "Tests SDL_IntersectFRect" , TEST_ENABLED
2097
2097
};
2098
2098
2099
2099
static const SDLTest_TestCaseReference rectTest34 = {
2100
2100
(SDLTest_TestCaseFp )rect_testUnionFRect , "rect_testUnionFRect" , "Tests SDL_UnionFRect" , TEST_ENABLED
2101
2101
};
2102
2102
2103
2103
static const SDLTest_TestCaseReference rectTest35 = {
2104
- (SDLTest_TestCaseFp )rect_testUnionFRect , "rect_testEncloseFPointsUnionFRect " , "Tests SDL_EncloseFPoints" , TEST_ENABLED
2104
+ (SDLTest_TestCaseFp )rect_testEncloseFPoints , "rect_testEncloseFPoints " , "Tests SDL_EncloseFPoints" , TEST_ENABLED
2105
2105
};
2106
2106
2107
2107
static const SDLTest_TestCaseReference rectTest36 = {
2108
- (SDLTest_TestCaseFp )rect_testUnionFRect , "rect_testIntersectFRectAndLine" , "Tests SDL_IntersectFRectAndLine" , TEST_ENABLED
2108
+ (SDLTest_TestCaseFp )rect_testIntersectFRectAndLine , "rect_testIntersectFRectAndLine" , "Tests SDL_IntersectFRectAndLine" , TEST_ENABLED
2109
2109
};
2110
2110
2111
2111
/* !
0 commit comments