2
Copyright (c) 2008-2009 NetAllied Systems GmbH
4
This file is part of MayaDataModel.
6
Licensed under the MIT Open Source License,
7
for details please see LICENSE file or the website
8
http://www.opensource.org/licenses/mit-license.php
10
#ifndef __MayaDM_SCULPT_H__
11
#define __MayaDM_SCULPT_H__
12
#include "MayaDMTypes.h"
13
#include "MayaDMConnectables.h"
14
#include "MayaDMGeometryFilter.h"
17
class Sculpt : public GeometryFilter
22
Sculpt():GeometryFilter(){}
23
Sculpt(FILE* file,const std::string& name,const std::string& parent="",bool shared=false,bool create=true)
24
:GeometryFilter(file, name, parent, "sculpt", shared, create){}
27
void setSculptObjectMatrix(const matrix& sm)
29
if(sm == identity) return;
30
fprintf(mFile,"\tsetAttr \".sm\" -type \"matrix\" ");
34
void setMode(unsigned int mo)
37
fprintf(mFile,"\tsetAttr \".mo\" %i;\n", mo);
39
void setInsideMode(unsigned int im)
42
fprintf(mFile,"\tsetAttr \".im\" %i;\n", im);
44
void setMaximumDisplacement(double md)
47
fprintf(mFile,"\tsetAttr \".md\" %f;\n", md);
49
void setDropoffDistance(double dd)
52
fprintf(mFile,"\tsetAttr \".dd\" %f;\n", dd);
54
void setDropoffType(unsigned int dt)
57
fprintf(mFile,"\tsetAttr \".dt\" %i;\n", dt);
59
void setStartPosition(const float3& sp)
61
fprintf(mFile,"\tsetAttr \".sp\" -type \"float3\" ");
65
void setStartPosX(float sx)
68
fprintf(mFile,"\tsetAttr \".sp.sx\" %f;\n", sx);
70
void setStartPosY(float sy)
73
fprintf(mFile,"\tsetAttr \".sp.sy\" %f;\n", sy);
75
void setStartPosZ(float sz)
78
fprintf(mFile,"\tsetAttr \".sp.sz\" %f;\n", sz);
80
void setExtendedEnd(bool exd)
82
if(exd == false) return;
83
fprintf(mFile,"\tsetAttr \".exd\" %i;\n", exd);
85
void getSculptObjectMatrix()const
87
fprintf(mFile,"\"%s.sm\"",mName.c_str());
89
void getSculptObjectGeometry()const
91
fprintf(mFile,"\"%s.sg\"",mName.c_str());
95
fprintf(mFile,"\"%s.mo\"",mName.c_str());
97
void getInsideMode()const
99
fprintf(mFile,"\"%s.im\"",mName.c_str());
101
void getMaximumDisplacement()const
103
fprintf(mFile,"\"%s.md\"",mName.c_str());
105
void getDropoffDistance()const
107
fprintf(mFile,"\"%s.dd\"",mName.c_str());
109
void getDropoffType()const
111
fprintf(mFile,"\"%s.dt\"",mName.c_str());
113
void getStartPosition()const
115
fprintf(mFile,"\"%s.sp\"",mName.c_str());
117
void getStartPosX()const
119
fprintf(mFile,"\"%s.sp.sx\"",mName.c_str());
121
void getStartPosY()const
123
fprintf(mFile,"\"%s.sp.sy\"",mName.c_str());
125
void getStartPosZ()const
127
fprintf(mFile,"\"%s.sp.sz\"",mName.c_str());
129
void getExtendedEnd()const
131
fprintf(mFile,"\"%s.exd\"",mName.c_str());
134
Sculpt(FILE* file,const std::string& name,const std::string& parent,const std::string& nodeType,bool shared=false,bool create=true)
135
:GeometryFilter(file, name, parent, nodeType, shared, create) {}
139
#endif//__MayaDM_SCULPT_H__