Panda3D
Public Member Functions | List of all members
QtessInputFile Class Reference

Stores all the information read from a tesselation input file: a list of QtessInputEntry's. More...

#include "qtessInputFile.h"

Public Member Functions

 QtessInputFile (const QtessInputFile &copy)
 
int count_tris ()
 Determines the tesselation u,v amounts of each attached surface, and stores this information in the surface pointer. More...
 
QtessInputEntryget_default_entry ()
 Returns a reference to the last entry on the list, which is the "default" entry that will match any surface that does not get explicitly named in the input file. More...
 
QtessInputEntry::Type match (QtessSurface *surface)
 Attempts to find a match for the given surface in the user input entries. More...
 
void operator= (const QtessInputFile &copy)
 
bool read (const Filename &filename)
 reads the input file. More...
 
void write (std::ostream &out, int indent_level=0) const
 

Detailed Description

Stores all the information read from a tesselation input file: a list of QtessInputEntry's.

Definition at line 28 of file qtessInputFile.h.

Member Function Documentation

◆ count_tris()

int QtessInputFile::count_tris ( )

Determines the tesselation u,v amounts of each attached surface, and stores this information in the surface pointer.

Returns the total number of tris that will be produced.

Definition at line 297 of file qtessInputFile.cxx.

◆ get_default_entry()

QtessInputEntry & QtessInputFile::get_default_entry ( )

Returns a reference to the last entry on the list, which is the "default" entry that will match any surface that does not get explicitly named in the input file.

Definition at line 254 of file qtessInputFile.cxx.

◆ match()

QtessInputEntry::Type QtessInputFile::match ( QtessSurface surface)

Attempts to find a match for the given surface in the user input entries.

Searches in the order in which the entries were defined, and chooses the first match.

When a match is found, the surface is added to the entry's set of matched surfaces. Returns the type of the matching node if a match is found, or T_undefined otherwise.

Definition at line 273 of file qtessInputFile.cxx.

◆ read()

bool QtessInputFile::read ( const Filename filename)

reads the input file.

Definition at line 31 of file qtessInputFile.cxx.

References extract_words(), Filename::open_read(), string_to_double(), trim(), and trim_right().


The documentation for this class was generated from the following files: