Maya 1.0
|
This class implements a set of instances along with their frame lists. More...
#include <maya.h>
Public Member Functions | |
MayaInstanceAll () | |
Empty. | |
~MayaInstanceAll () | |
Empty. | |
void | Append (const MayaInstance &) |
Add an instance to the scene. More... | |
void | Append (const MayaInstanceSet &) |
Add an instance set to the scene. More... | |
void | Append (const MayaInstanceAll &) |
Append a set of instances with the existing one. More... | |
void | Append (const QString &, const FrameScaled &) |
Add an instance to the scene. More... | |
void | AppendNew (const MayaInstanceSet &) |
Add an instance set to the scene. More... | |
QList< QString > | GetNames () const |
Get the list of names from the set of instances. | |
MayaInstanceSet | operator[] (const QString &) const |
Get one set from the list of all instances. More... | |
void | Rotate (const Vector &) |
Rotate all instances. More... | |
void | Translate (const Vector &) |
Translate all instances. More... | |
void | Scale (const Vector &) |
Scale all instances. More... | |
void | Remove (const QString &) |
Clears one instance by name. More... | |
void | Clear () |
Clears all instances. | |
void | ClearFrames () |
Clears frames of all instances. | |
MayaInstanceAll | Crop (const Box2 &) const |
Get a crop of the instances. More... | |
QVector< FrameScaled > | GetFrameScaleds (const QString &) const |
Get the set of frames from the list of all instances. More... | |
bool | LoadInstances (const QString &) |
Load instances with a maya file. More... | |
QString | ExportVueScript () |
Export Vue 7 script. | |
void | exportSceneJson (QTextStream &out, const QString &url) const |
Export scene with Json. | |
QString | GetText (int=0, bool=false) const |
Get the text information. More... | |
Protected Attributes | |
QMap< QString, MayaInstanceSet > | instances |
Map between names and set of instances. | |
Friends | |
class | MayaGeometryAll |
This class implements a set of instances along with their frame lists.
void MayaInstanceAll::Append | ( | const MayaInstance & | in | ) |
Add an instance to the scene.
This function checks if the object already exists in the collection of instances. If it already exists, it simply creates a new reference to it, otherwise it creates a new entry with the identity matrix.
in | The instance. |
References MayaInstance::GetName(), FrameScaled::Id, and instances.
Referenced by MayaSceneStack::AddInstanceToScene(), Append(), MayaGeometryAll::CreateVoxelSurface(), Crop(), and LoadInstances().
void MayaInstanceAll::Append | ( | const MayaInstanceAll & | scene | ) |
void MayaInstanceAll::Append | ( | const MayaInstanceSet & | ins | ) |
Add an instance set to the scene.
This function checks if the object already exists in the collection of models. If so, it simply creates a new reference to it, otherwise it creates a new entry.
ins | The instance. |
References MayaInstanceSet::GetFrameScaleds(), MayaInstance::GetName(), and instances.
void MayaInstanceAll::Append | ( | const QString & | name, |
const FrameScaled & | frame | ||
) |
Add an instance to the scene.
This function checks if the object already exists in the collection of instances. If it already exists, it simply creates a new reference to it with the frame,otherwise it creates a new entry with the argument frame.
name | Name of the instance. |
frame | The frame. |
References instances.
void MayaInstanceAll::AppendNew | ( | const MayaInstanceSet & | ins | ) |
Add an instance set to the scene.
This function creates a new entry without checking the name of the object.
ins | The instance. |
References MayaInstance::GetName(), and instances.
MayaInstanceAll MayaInstanceAll::Crop | ( | const Box2 & | box | ) | const |
Get a crop of the instances.
box | The Crop boundary. |
References Append(), MayaInstanceSet::GetFrameScaleds(), and instances.
|
inline |
Get the set of frames from the list of all instances.
n | The name. |
References instances.
Referenced by MayaGeometryAll::MayaGeometryAll().
QString MayaInstanceAll::GetText | ( | int | spaces = 0 , |
bool | html = false |
||
) | const |
Get the text information.
spaces | Spacing for indenting the text. |
html | Flag to specify syntax highlighting. |
References instances.
Referenced by MayaSceneStack::GetText().
bool MayaInstanceAll::LoadInstances | ( | const QString & | file | ) |
Load instances with a maya file.
file | Name of the file. |
References Append(), Math::Pi, and Matrix::Rotation().
|
inline |
void MayaInstanceAll::Remove | ( | const QString & | n | ) |
void MayaInstanceAll::Rotate | ( | const Vector & | r | ) |
void MayaInstanceAll::Scale | ( | const Vector & | s | ) |