From 0ea5fc66924303d1bf73ba283a383e2aadee02f2 Mon Sep 17 00:00:00 2001 From: neodarz Date: Sat, 11 Aug 2018 20:21:34 +0200 Subject: Initial commit --- docs/doxygen/nel/a03381.html | 280 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 280 insertions(+) create mode 100644 docs/doxygen/nel/a03381.html (limited to 'docs/doxygen/nel/a03381.html') diff --git a/docs/doxygen/nel/a03381.html b/docs/doxygen/nel/a03381.html new file mode 100644 index 00000000..6704f337 --- /dev/null +++ b/docs/doxygen/nel/a03381.html @@ -0,0 +1,280 @@ + + +NeL: NL3D::CShapeStream class Reference + + + +
+

NL3D::CShapeStream Class Reference

#include <shape.h> +

+


Detailed Description

+This class is used to serialize a shape. In reading, just create a CShapeStream object and serial your class with your input stream using "serial (IStream&)". Then take back the shape pointer. It is yours. In writing, create a CShapeStream object with a pointer on the IShape you want to serialize and serial it with "serial (IStream&)". You have to register all the IShape derived classes you want to serial.
See also:
IShape CClassRegistry
+ +

+ +

+Definition at line 178 of file shape.h. + + + + + + + + + + + + + + + + + +

Public Member Functions

 CShapeStream (IShape *shape)
 CShapeStream ()
 Default constructor. Set the IShape pointer to NULL.

IShapegetShapePointer () const
virtual void serial (NLMISC::IStream &f) throw (NLMISC::EStream)
 serial the shape.

void setShapePointer (IShape *shape)

Private Attributes

IShape_Shape
+


Constructor & Destructor Documentation

+

+ + + + +
+ + + + + + + + + +
NL3D::CShapeStream::CShapeStream  ) 
+
+ + + + + +
+   + + +

+Default constructor. Set the IShape pointer to NULL. +

+ +

+Definition at line 91 of file shape.cpp. +

+

00092 {
+00093         _Shape=NULL;
+00094 }
+
+

+ + + + +
+ + + + + + + + + + +
NL3D::CShapeStream::CShapeStream IShape shape  ) 
+
+ + + + + +
+   + + +

+Constructor. Get a IShape pointer. Used to output serialization.

Parameters:
+ + +
shape the pointer on the IShape derived object you want to serialize.
+
+ +

+Definition at line 98 of file shape.cpp. +

+References setShapePointer(). +

+

00099 {
+00100         // Set the pointer
+00101         setShapePointer (shape);
+00102 }
+
+


Member Function Documentation

+

+ + + + +
+ + + + + + + + + +
IShape * NL3D::CShapeStream::getShapePointer  )  const
+
+ + + + + +
+   + + +

+Get the pointer to the IShape object. Used to serial a shape in input.

Returns:
shape the pointer on the IShape derived object serialized.
+ +

+Definition at line 113 of file shape.cpp. +

+Referenced by NL3D::CInstanceLighter::light(), NL3D::CInstanceLighter::lightIgSimple(), NL3D::CShapeBank::load(), and NL3D::CAsyncFileManager3D::CMeshLoad::run(). +

+

00114 {
+00115         return _Shape;
+00116 }
+
+

+ + + + +
+ + + + + + + + + + +
void NL3D::CShapeStream::serial NLMISC::IStream f  )  throw (NLMISC::EStream) [virtual]
+
+ + + + + +
+   + + +

+serial the shape. +

+ +

+Definition at line 120 of file shape.cpp. +

+References uint32. +

+Referenced by NL3D::CInstanceLighter::light(), and NL3D::CInstanceLighter::lightIgSimple(). +

+

00121 {
+00122         // First, serial an header or checking if it is correct
+00123         f.serialCheck ((uint32)'PAHS');
+00124 
+00125         // Then, serial the shape
+00126         f.serialPolyPtr (_Shape);
+00127 
+00128         // Ok, it's done
+00129 }
+
+

+ + + + +
+ + + + + + + + + + +
void NL3D::CShapeStream::setShapePointer IShape shape  ) 
+
+ + + + + +
+   + + +

+Set the pointer to the IShape object. Used to serial a shape in output.

Parameters:
+ + +
shape the pointer on the IShape derived object you want to serialize.
+
+ +

+Definition at line 106 of file shape.cpp. +

+Referenced by CShapeStream(). +

+

00107 {
+00108         _Shape=shape;
+00109 }
+
+


Field Documentation

+

+ + + + +
+ + +
IShape* NL3D::CShapeStream::_Shape [private] +
+
+ + + + + +
+   + + +

+ +

+Definition at line 202 of file shape.h.

+


The documentation for this class was generated from the following files: +
Generated on Tue Mar 16 07:44:15 2004 for NeL by + +doxygen +1.3.6
+ + -- cgit v1.2.1