SoByteStream — converts scene graph objects to character byte streams
Contents
Description
This class creates a byte stream representation of a scene graph, using an SoWriteAction to write path
lists to an in-memory buffer. Byte streams are commonly used to transfer data in copy and paste
operations. (The SoXtClipboard class passes SoByteStream data during copy and paste.)
Inherits From
SoByteStream
Methods
SoByteStream()~SoByteStream()
Constructor and destructor.
voidconvert(SoNode*node,SbBoolbinaryFormat=TRUE)voidconvert(SoPath*path,SbBoolbinaryFormat=TRUE)voidconvert(SoPathList*pathList,SbBoolbinaryFormat=TRUE)
These convert the passed scene graph object(s) into a byte stream. The caller may specify whether the
byte stream is written in binary (TRUE) or ASCII (FALSE) format, and can pass the object(s) by node,
path, or pathList.
void*getData()uint32_tgetNumBytes()
These return the data and number of bytes from the last convert() operation. This byte stream format
is well suited to data transfers, like copy and paste.
staticSoPathList*unconvert(SoByteStream*byteStream)staticSoPathList*unconvert(void*data,uint32_tnumBytes)
These take byte stream data and unconvert it back to scene graph objects. The objects are returned in
a path list.
Name
SoByteStream — converts scene graph objects to character byte streams
See Also
SoXtClipboardSoByteStream(3IV)()
Synopsis
#include<Inventor/misc/SoByteStream.h>
Methods from class SoByteStream:
SoByteStream()~SoByteStream()voidconvert(SoNode*node,SbBoolbinaryFormat=TRUE)voidconvert(SoPath*path,SbBoolbinaryFormat=TRUE)voidconvert(SoPathList*pathList,SbBoolbinaryFormat=TRUE)void*getData()uint32_tgetNumBytes()staticSoPathList*unconvert(SoByteStream*byteStream)staticSoPathList*unconvert(void*data,uint32_tnumBytes)