31 INLINE PT(InternalName) InternalName::
32 make(
const string &name) {
33 return get_root()->append(name);
50 INLINE PT(InternalName) InternalName::
51 make(
const char (&literal)[N]) {
53 LiteralTable::const_iterator it = _literal_table.find(literal);
55 if (it == _literal_table.end()) {
56 PT(InternalName) name = get_root()->append(literal);
57 _literal_table.insert(LiteralTable::value_type(literal, name));
70 INLINE InternalName *InternalName::
82 INLINE
const string &InternalName::
83 get_basename()
const {
95 INLINE PT(InternalName) InternalName::
97 if (_root == (InternalName *)NULL) {
98 _root =
new InternalName(NULL,
"");
108 INLINE PT(InternalName) InternalName::
110 if (_error == (InternalName *)NULL) {
111 _error = InternalName::make(
"error");
123 INLINE PT(InternalName) InternalName::
125 if (_vertex == (InternalName *)NULL) {
126 _vertex = InternalName::make(
"vertex");
138 INLINE PT(InternalName) InternalName::
140 if (_normal == (InternalName *)NULL) {
141 _normal = InternalName::make(
"normal");
156 INLINE PT(InternalName) InternalName::
158 if (_tangent == (InternalName *)NULL) {
159 _tangent = InternalName::make(
"tangent");
172 INLINE PT(InternalName) InternalName::
173 get_tangent_name(
const string &name) {
174 return get_tangent()->append(name);
188 INLINE PT(InternalName) InternalName::
190 if (_binormal == (InternalName *)NULL) {
191 _binormal = InternalName::make(
"binormal");
204 INLINE PT(InternalName) InternalName::
205 get_binormal_name(
const string &name) {
206 return get_binormal()->append(name);
218 INLINE PT(InternalName) InternalName::
220 if (_texcoord == (InternalName *)NULL) {
221 _texcoord = InternalName::make(
"texcoord");
235 INLINE PT(InternalName) InternalName::
236 get_texcoord_name(
const string &name) {
237 return get_texcoord()->append(name);
247 INLINE PT(InternalName) InternalName::
249 if (_color == (InternalName *)NULL) {
250 _color = InternalName::make(
"color");
264 INLINE PT(InternalName) InternalName::
266 if (_rotate == (InternalName *)NULL) {
267 _rotate = InternalName::make(
"rotate");
281 INLINE PT(InternalName) InternalName::
283 if (_size == (InternalName *)NULL) {
284 _size = InternalName::make(
"size");
298 INLINE PT(InternalName) InternalName::
300 if (_aspect_ratio == (InternalName *)NULL) {
301 _aspect_ratio = InternalName::make(
"aspect_ratio");
303 return _aspect_ratio;
315 INLINE PT(InternalName) InternalName::
316 get_transform_blend() {
317 if (_transform_blend == (InternalName *)NULL) {
318 _transform_blend = InternalName::make(
"transform_blend");
320 return _transform_blend;
336 INLINE PT(InternalName) InternalName::
337 get_transform_weight() {
338 if (_transform_weight == (InternalName *)NULL) {
339 _transform_weight = InternalName::make(
"transform_weight");
341 return _transform_weight;
357 INLINE PT(InternalName) InternalName::
358 get_transform_index() {
359 if (_transform_index == (InternalName *)NULL) {
360 _transform_index = InternalName::make(
"transform_index");
362 return _transform_index;
377 INLINE PT(InternalName) InternalName::
378 get_morph(InternalName *column,
const string &slider) {
383 return column->append(
"morph")->append(slider);
395 INLINE PT(InternalName) InternalName::
397 if (_index == (InternalName *)NULL) {
398 _index = InternalName::make(
"index");
409 INLINE PT(InternalName) InternalName::
411 if (_world == (InternalName *)NULL) {
412 _world = InternalName::make(
"world");
423 INLINE PT(InternalName) InternalName::
425 if (_camera == (InternalName *)NULL) {
426 _camera = InternalName::make(
"camera");
437 INLINE PT(InternalName) InternalName::
439 if (_model == (InternalName *)NULL) {
440 _model = InternalName::make(
"model");
451 INLINE PT(InternalName) InternalName::
453 if (_view == (InternalName *)NULL) {
454 _view = InternalName::make(
"view");
465 operator << (ostream &out,
const InternalName &tcn) {
476 INLINE CPT_InternalName::
477 CPT_InternalName(
const InternalName *ptr) :
487 INLINE CPT_InternalName::
498 INLINE CPT_InternalName::
509 INLINE CPT_InternalName::
510 CPT_InternalName(
const string &name) :
521 INLINE CPT_InternalName::
522 CPT_InternalName(
const char (&literal)[N]) :
527 #ifdef USE_MOVE_SEMANTICS 533 INLINE CPT_InternalName::
544 INLINE CPT_InternalName::
557 this->reassign(move(from));
568 this->reassign(move(from));
571 #endif // USE_MOVE_SEMANTICS 579 operator = (
const To *ptr) {
580 this->reassign((To *)ptr);
This is a const pointer to an InternalName, and should be used in lieu of a CPT(InternalName) in func...
Similar to MutexHolder, but for a light mutex.
A ConstPointerTo is similar to a PointerTo, except it keeps a const pointer to the thing...
PointerTo is a template class which implements a smart pointer to an object derived from ReferenceCou...