Builder/Builder/Common/plyfile.c
/******************************************************************************
Find a property in the list of properties of a given element.

Entry:
  elem      - pointer to element in which we want to find the property
  prop_name - name of property to find

Exit:
  index - index to position in list
  returns a pointer to the property, or NULL if not found
******************************************************************************/
Find a property in the list of properties of a given element.
Entry:
elem      - pointer to element in which we want to find the property
prop_name - name of property to find

index to position in list
returns a pointer to the property, or NULL if not found
Find a property in the list of properties of a given element . Entry : elem - pointer to element in which we want to find the property prop_name - name of property to find index to position in list returns a pointer to the property or NULL if not found
PlyProperty *find_property(PlyElement *elem, char *prop_name, int *index)
{
  int i;
  for (i = 0; i < elem->nprops; i++)
    if (equal_strings (prop_name, elem->props[i]->name)) {
      *index = i;
      return (elem->props[i]);
    }
  *index = -1;
  return (NULL);
}
PlyProperty * find_property ( PlyElement * elem , char * prop_name , int * index ) { int i ; for ( i = 0 ; i < elem -> nprops ; i ++ ) if ( equal_strings ( prop_name , elem -> props [ i ] -> name ) ) { * index = i ; return ( elem -> props [ i ] ) ; } * index = -1 ; return ( NULL ) ; }
Find a property in the list of properties of a given element.
Find a property in the list of properties of a given element .