Macros | Functions
vgl_triangle_test.hxx File Reference
#include "vgl_triangle_test.h"

Go to the source code of this file.

Macros

#define VGL_TRIANGLE_TEST_INSTANTIATE(T)
 

Functions

template<class T >
vgl_triangle_test_discriminant (T x1, T y1, T x2, T y2, T x3, T y3)
 Compute discriminant function. More...
 
template<class T >
bool vgl_triangle_test_inside (T x1, T y1, T x2, T y2, T x3, T y3, T x, T y)
 Function returns true if (x, y) is inside, or on the boundary of triangle. More...
 

Detailed Description

Author
fsm

Definition in file vgl_triangle_test.hxx.

Macro Definition Documentation

◆ VGL_TRIANGLE_TEST_INSTANTIATE

#define VGL_TRIANGLE_TEST_INSTANTIATE (   T)
Value:
template T vgl_triangle_test_discriminant(T, T, T, T, T, T); \
template bool vgl_triangle_test_inside(T, T, T, T, T, T, T, T)
bool vgl_triangle_test_inside(T x1, T y1, T x2, T y2, T x3, T y3, T x, T y)
Function returns true if (x, y) is inside, or on the boundary of triangle.
T vgl_triangle_test_discriminant(T x1, T y1, T x2, T y2, T x3, T y3)
Compute discriminant function.

Definition at line 43 of file vgl_triangle_test.hxx.

Function Documentation

◆ vgl_triangle_test_discriminant()

template<class T >
T vgl_triangle_test_discriminant ( x1,
y1,
x2,
y2,
x3,
y3 
)

Compute discriminant function.

Returns determinant of

 [ x1 x2 x3 ]
 [ y1 y2 y3 ]
 [ 1  1  1  ]

Definition at line 11 of file vgl_triangle_test.hxx.

◆ vgl_triangle_test_inside()

template<class T >
bool vgl_triangle_test_inside ( x1,
y1,
x2,
y2,
x3,
y3,
x,
y 
)

Function returns true if (x, y) is inside, or on the boundary of triangle.

The triangle whose vertices are (xi, yi), i=1,2,3.

Definition at line 19 of file vgl_triangle_test.hxx.