OK, I'll change it now.
 
-- Peter.


--

Från: Sean McBride <sean@rogue-research.com>

Well, I'm not familiar with the code, or what it's trying to do, but I'd say UINT_MAX.  The C++ standard does not guarantee that 'int' is 32 bits, so 0xffffffff and UINT_MAX are not necessarily the same.

Sean

On Thu, 29 Mar 2012 20:07:08 +0100, Peter Vanroose said:

>Sorry Sean,
>it seems like I had roughly the same idea as you, before I saw your post;
>but I used 0xffffffff instead of UINT_MAX.
>
>Which of the two is preferred?
>
>
>--    Peter.
>
>
>Sean McBride wrote:
>Index: core/vgl/vgl_triangle_3d.cxx
>===================================================================
>--- core/vgl/vgl_triangle_3d.cxx    (revision 34632)
>+++ core/vgl/vgl_triangle_3d.cxx    (working copy)
>@@ -375,7 +375,7 @@

> namespace
> {
>-  static const unsigned calc_edge_index_lookup[8] = {-1, 0, 2, 0, -1,
>1, 2, 1};
>+  static const unsigned calc_edge_index_lookup[8] = {UINT_MAX, 0, 2, 0,
>UINT_MAX, 1, 2, 1};
>   //: Given the [0,2] index of two vertices, in either order, return
>the edge index [0,2]
>   // E.g. between vertices 2 and 0 is edge 2.
>   // Use precalculated list lookup, probably fastest.