/***************************************************************************
object.h - description
-------------------
begin : Wed Dec 6 2000
copyright : (C) 2000 by Jan Walter
email : jan@blender.nl
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
***************************************************************************/
#ifndef OBJECT_H
#define OBJECT_H
#include <blender.h>
struct PyObject;
/**Blender objects can be seen in the OOPS window as gray rectangles. The have mainly a matrix and a connection to associated data like a mesh.
*@author Jan Walter
*/
class Object : public Blender {
public:
Object();
~Object();
/** A Blender object has always a unique name. The name you give as an argument is only a proposal for the real name. Blender will check if this name is already used and rename the object if necessary. */
Object(const char* name);
private: // Private attributes
/** All rectangles you can see in the OOPS window are instances of classes with an unique name for all instances of this class. Nevertheless the name of two instances of different classes can be the same. */
char* name;
/** The matrix is stored in a PyObject for the usage of it within Python. This is a list of lists to represent a 4x4 matrix. This might change in the future. */
PyObject* matrix;
/** This holds the 4x4 inverse matrix as a list of lists for usage within Python. */
PyObject* inverseMatrix;
/** The variable materials holds a list of names for usage within Python. The names can be used to get the real material settings by calling the function getMaterial(name). */
PyObject* materials;
/** To know within Python which type the connected data has this variable is either None (no connected data) or a the name of a valid class. The name stored in data can be used to get the real data (e.g. if type == "Mesh": mesh = getMesh(name)). */
PyObject* type;
/** To know within Python which type the connected data has the type variable names the class and this variable is either None (no connected data) or a valid name. This name can be used to get the real data (e.g. if type == "Mesh": mesh = getMesh(name)). */
PyObject* data;
/** This is part of the data you can see in Blender by pressing NKEY. You can access this data also with LocX, LocY, LocZ instead of loc[0], loc[1], loc[2]. */
PyObject* loc;
/** This is part of the data you can see in Blender by pressing NKEY. You can access this data also with dLocX, dLocY, dLocZ instead of dloc[0], dloc[1], dloc[2]. */
PyObject* dloc;
/** This is part of the data you can see in Blender by pressing NKEY. You can access this data also with RotX, RotY, RotZ instead of rot[0], rot[1], rot[2]. */
PyObject* rot;
/** This is part of the data you can see in Blender by pressing NKEY. You can access this data also with dRotX, dRotY, dRotZ instead of drot[0], drot[1], drot[2]. */
PyObject* drot;
/** This is part of the data you can see in Blender by pressing NKEY. You can access this data also with SizeX, SizeY, SizeZ instead of size[0], size[1], size[2]. */
PyObject* size;
/** This is part of the data you can see in Blender by pressing NKEY. You can access this data also with dSizeX, dSizeY, dSizeZ instead of dsize[0], dsize[1], dsize[2]. */
PyObject* dsize;
};
#endif
Documentation generated by jan@nvidea on Mon Mar 5 16:57:27 CET 2001