89 virtual const char *
getToken()
const = 0;
90 virtual const char *getLabel()
const = 0;
96 virtual bool checkFilename(
const char *
filename,
98 virtual bool checkFilename(
const char *
filename,
105 virtual bool checkByteMagic(
uint8 first_byte,
109 virtual bool statFile(
const char *
filename,
150 static bool createInfoAttribute(
152 const char *format_token,
157 const char *attrib_name,
161 static bool destroyInfoAttribute(
GA_Detail &
g,
162 const char *attrib_name);
190 , myBaseStream(nullptr)
193 , myScfReader(nullptr)
200 , myBaseStream(nullptr)
203 , myScfReader(nullptr)
206 open(io, filename, errors);
214 bool isValid()
const {
return myStream !=
nullptr; }
254 open(io, filename, errors);
262 bool isValid()
const {
return myStream !=
nullptr; }
268 std::ostream *
open(
const GA_IO &io,
const char *
filename,
273 std::ostream *myStream;
311 bool create_attributes=
false)
const;
bool isValid() const
Check if the stream is valid.
const FS_Reader * reader() const
Provide access to the FS_Reader (this may be nullptr)
GT_API const UT_StringHolder filename
bool setLoadCounts(GA_Detail &gdp, GA_Size npoints, GA_Size nvertex, GA_Size nprimitive, GA_LoadMap &loadmap) const
UT_IStream * getStream() const
Get the UT_IStream associated with the handle.
Used to pass options and map offset values during saving.
const GLuint GLenum const void * binary
virtual bool readCheckCompressed() const =0
virtual bool writeCheckStdout() const
virtual bool writeStream(const GA_Detail &g, std::ostream &os, bool binary, const GA_SaveOptions *opts, UT_StringArray *errors) const =0
Write geometry to an output stream.
JSON reader class which handles parsing of JSON or bJSON files.
Class which writes ASCII or binary JSON streams.
exint GA_Size
Defines the bit width for index and offset types in GA.
std::ostream * getStream() const
Get the output stream.
bool isValid() const
Test whether the read handle is valid.
io_ReadHandle(const GA_IO &io, const char *filename, UT_StringArray *errors)
SYS_FORCE_INLINE UT_StringHolder getToken(Add enum_value)
virtual bool writeFile(const GA_Detail &g, const char *filename, const GA_SaveOptions *opts, UT_StringArray *errors) const
bool jsonSavePointReference(const GA_Detail &gdp, UT_JSONWriter &w, const GA_SaveMap &savemap) const
bool rebuildTopology(GA_Detail &gdp, bool create_attributes=false) const
virtual bool readStream(GA_Detail &g, UT_IStream &is, const GA_LoadOptions *opts, UT_StringArray *errors) const =0
Load geometry from an input stream.
A map of string to various well defined value types.
Class to return information about a GA_Detail.
bool isStdout(const char *filename) const
io_WriteHandle(const GA_IO &io, const char *filename, UT_StringArray *errors)
virtual bool readFile(GA_Detail &g, const char *filename, const GA_LoadOptions *opts, UT_StringArray *errors) const
Class which defines an I/O interface to save/load geometry.
Container class for all geometry.
Interface for reading Seekable Compressed Format (SCF) files.
GLubyte GLubyte GLubyte GLubyte w
virtual bool readCheckStdin() const
Class to specify options for loading geometry.
bool jsonLoadPointReference(GA_Detail &gdp, UT_JSONParser &p, const GA_LoadMap &loadmap) const
bool isStdin() const
Test whether the read handle reads from stdin.