|
|
@@ -0,0 +1,43 @@
|
|
|
+// Filename: lwoSurfaceBlockTransform.cxx
|
|
|
+// Created by: drose (24Apr01)
|
|
|
+//
|
|
|
+////////////////////////////////////////////////////////////////////
|
|
|
+
|
|
|
+#include "lwoSurfaceBlockTransform.h"
|
|
|
+#include "lwoInputFile.h"
|
|
|
+
|
|
|
+#include <indent.h>
|
|
|
+
|
|
|
+TypeHandle LwoSurfaceBlockTransform::_type_handle;
|
|
|
+
|
|
|
+////////////////////////////////////////////////////////////////////
|
|
|
+// Function: LwoSurfaceBlockTransform::read_iff
|
|
|
+// Access: Public, Virtual
|
|
|
+// Description: Reads the data of the chunk in from the given input
|
|
|
+// file, if possible. The ID and length of the chunk
|
|
|
+// have already been read. stop_at is the byte position
|
|
|
+// of the file to stop at (based on the current position
|
|
|
+// at in->get_bytes_read()). Returns true on success,
|
|
|
+// false otherwise.
|
|
|
+////////////////////////////////////////////////////////////////////
|
|
|
+bool LwoSurfaceBlockTransform::
|
|
|
+read_iff(IffInputFile *in, size_t stop_at) {
|
|
|
+ LwoInputFile *lin = DCAST(LwoInputFile, in);
|
|
|
+
|
|
|
+ _vec = lin->get_vec3();
|
|
|
+ _envelope = lin->get_vx();
|
|
|
+
|
|
|
+ return true;
|
|
|
+}
|
|
|
+
|
|
|
+////////////////////////////////////////////////////////////////////
|
|
|
+// Function: LwoSurfaceBlockTransform::write
|
|
|
+// Access: Public, Virtual
|
|
|
+// Description:
|
|
|
+////////////////////////////////////////////////////////////////////
|
|
|
+void LwoSurfaceBlockTransform::
|
|
|
+write(ostream &out, int indent_level) const {
|
|
|
+ indent(out, indent_level)
|
|
|
+ << get_id() << " { vec = " << _vec
|
|
|
+ << ", envelope = " << _envelope << " }\n";
|
|
|
+}
|