template <class T> // or template <typename T> class A { public: A() {} ~A() {} void aaa() …
#define LIFESPAN 0x000002 bool hasLifespan( int attrBitMask ) { return ( attrBitMask & LIFESPAN ); } 위와 같은 code가 있다고 했을 때, 다음과 같은 경고(warning)이 발생할…
#include <Process.h> int main( int argc, char** argv ) { system( "ls" ); return 0; } 이러한 방식으로 system() 함수를 이용하여 외부 프로그램을 실행할 수…
class A { public: int &x; int y; A(): x(y), y(0) {}; }; int main( int argc, char** argv ) { A a; cout <<…
class A { public: int data[2]; int &x, &y; A(): x(data[0]), y(data[1]) {} A( int xx, int yy ): x(data[0]),…
void aaa( char* str ) { … } 일 때, aaa( “abcdefg” ); 라고 실행하면 발생하는 에러이다. 두 가지의 해결방법이 있다. 첫 번째, void aaa(…
class A { public: int a, b; A(): b(0), a(0) {} }; 만약 위와 같은 code를 사용했을 때, gcc에서 다음과 같은 warning이…
“undefined refernce to…” 이러한 error는 source code에서 어떤 외부 library를 사용하지만 해당 library가 link되어 있지 않아서 code 내용을 가져올 수 없기 때문에 발생하는 error이다. 여기서는…
class A { public: float x; A(): x(0) {} }; std::vector av; A a; av.push_back( a ); 했을 때, can’t use default…
Visual Studio에서 다음과 같은 compile error가 발생할 때가 있다. UTL error C2872: ‘ostream’ : ambiguous symbol 이럴 때에는 C/C++ -> Preprocesser -> Preprocessor Definations에 REQUIRE_IOSTREAM를…
다음과 같은 error가 발생할 때, C:\Program Files (x86)\Microsoft Visual Studio 8\VC\PlatformSDK\include\windef.h(122) : warning C4005: ‘CALLBACK’ : macro redefinition C:\Program Files (x86)\Microsoft Visual Studio 8\VC\include\GL/glut.h(34)…
C:\Program Files\Microsoft Visual Studio 8\VC\include\stdlib.h(406) : error C2381: ‘exit’ : redefinition; __declspec(noreturn) differs C:\Program Files\Microsoft Visual Studio 8\VC\include\GL/glut.h(146) : see declaration of ‘exit’ \sourceCode\main.cpp(362) :…
[Test environment] CentOS 5.4 Maya 2011 x64 [Test Code (mel)] polySphere; select -r pSphere1.map[0]; int $i = 0; for( ; $i<100000; ++$i ) { …
I developed my own smoke simulator and rendered the data using Maya, but met a problem. MFnFluid fluidFn( fDagPath ); unsigned int Nx, Ny, Nz; fluidFn.getResolution(…
Maya에서 addattr로 dynamic attribute를 compound 형식으로 만들고 나서, deleteattr로 지운 뒤, 다시 같은 이름의 dynamic attribute를 addattr로 생성하면 다음과 같은 error가 발생하며 실패하게 된다. Too many…
MItMeshPolygon::getArea does not work in World Space. The Object Space area is always returned. Workaround Use MItMeshPolygon::getTriangles to get the triangles in World Space; then…
[bad usage] particle -q -attribute position -order 7; // Error: No object matches name: position // [good usage] particle -attribute position -order 7 -q particleShape1;…
Very simple maya command plug-in code. #include #include #include #include class test : public MPxCommand { public: virtual MStatus doIt ( const MArgList& ); static void* creator()…