Builder/Builder/Common/plyfile.c
/******************************************************************************
Specify a piece of object information (arbitrary text) that will be written
in the header.

Entry:
  plyfile  - file identifier
  obj_info - the text information to be written
******************************************************************************/
Specify a piece of object information (arbitrary text) that will be written
in the header.

plyfile  - file identifier
obj_info - the text information to be written
Specify a piece of object information ( arbitrary text ) that will be written in the header . plyfile - file identifier obj_info - the text information to be written
void ply_put_obj_info(PlyFile *plyfile, char *obj_info)
{
  if (plyfile->num_obj_info == 0)
    plyfile->obj_info = (char **) myalloc (sizeof (char *));
  else
    plyfile->obj_info = (char **) realloc (plyfile->obj_info,
                         sizeof (char *) * (plyfile->num_obj_info + 1));
  plyfile->obj_info[plyfile->num_obj_info] = _strdup (obj_info);
  plyfile->num_obj_info++;
}
void ply_put_obj_info ( PlyFile * plyfile , char * obj_info ) { if ( plyfile -> num_obj_info == 0 ) plyfile -> obj_info = ( char * * ) myalloc ( sizeof ( char * ) ) ; else plyfile -> obj_info = ( char * * ) realloc ( plyfile -> obj_info , sizeof ( char * ) * ( plyfile -> num_obj_info + 1 ) ) ; plyfile -> obj_info [ plyfile -> num_obj_info ] = _strdup ( obj_info ) ; plyfile -> num_obj_info ++ ; }
Specify a piece of object information (arbitrary text) that will be written
in the header.
Specify a piece of object information ( arbitrary text ) that will be written in the header .
/* (re)allocate space for new info */ /* add info to list */