-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Issue including #include <glm/gtc/quaternion.hpp> #2
Comments
Hi, What compiler are you using? Thanks, |
I'm using Visual Studio 2012 with the following Platform Toolsets: Visual Studio 2012 (v110). Sry, forgotten to mention it :) |
erm... I actually really don't understand what's causing this issue... Can you try GLM 0.9.4 branch https://github.com/g-truc/glm/zipball/0.9.4 and confirm the problem? If you still have an issue can you send me a code to reproduce the issue? Thanks, |
I tried it and visual studio still gives me the same errors. I'm using DirectX 9 and OpenGL 4.3 ... its a very large code base but I'm using the following code: GlobalHeader.h: in the global header file I've the following typedefs: dmGLTriangleNode.cpp: #include < glm/gtc/matrix_transform.hpp > glm::mat4 trans = glm::rotate(dmMatrix4(1.0f), mAngle*=0.4f , VECTOR_UP); this->mShader.VBind(); int locationProjection = this->mShader.GetLocation("projectionMatrix"); glUniformMatrix4fv(locationProjection, 1, GL_FALSE, glm::value_ptr(pScene->GetCamera()->GetProjection())); whenever I use glm::value_ptr(); it gives me the error with the quaternion.hpp since there is a overloaded function for quaternions. I excluded the overload function of value_ptr and it works but ran into another issue with the glm::rotate function as described above. |
Hi, I still have no solution for you... Is there any chance that your application is actually defining "value_ptr" with a define? Thanks, |
Everytime I try to include #include glm/gtc/quaternion.hpp I get alot of errors:
Error 1 error C2059: syntax error : 'constant' glm\gtc\quaternion.hpp 59 1
Error 2 error C2143: syntax error : missing ';' before '}' glm\gtc\quaternion.hpp 59 1
Error 3 error C2238: unexpected token(s) preceding ';' glm\gtc\quaternion.hpp 59 1
Error 4 error C2039: 'length' : is not a member of 'glm::detail::tquat' glm\gtc\quaternion.inl 38 1
Error 5 error C2039: '{ctor}' : is not a member of 'glm::detail::tquat' glm\gtc\quaternion.inl 46 1
Warning 6 warning C4346: '{ctor}' : dependent name is not a type glm\gtc\quaternion.inl 51 1
Error 7 error C2061: syntax error : identifier 'value_type' glm\gtc\quaternion.inl 51 1
Error 8 error C2039: '{ctor}' : is not a member of 'glm::detail::tquat' glm\gtc\quaternion.inl 58 1
Warning 9 warning C4346: '{ctor}' : dependent name is not a type glm\gtc\quaternion.inl 63 1
Error 10 error C2061: syntax error : identifier 'value_type' glm\gtc\quaternion.inl 63 1
Error 11 error C2039: '{ctor}' : is not a member of 'glm::detail::tquat' glm\gtc\quaternion.inl 72 1
Error 12 error C2039: '{ctor}' : is not a member of 'glm::detail::tquat'glm\gtc\quaternion.inl 108 1
Error 13 error C2039: '{ctor}' : is not a member of 'glm::detail::tquat' glm\gtc\quaternion.inl 117 1
Error 14 error C2039: '{ctor}' : is not a member of 'glm::detail::tquat' glm\gtc\quaternion.inl 126 1
Error 15 error C2039: '[]' : is not a member of 'glm::detail::tquat' glm\gtc\quaternion.inl 135 1
Error 16 error C2039: '[]' : is not a member of 'glm::detail::tquat' glm\gtc\quaternion.inl 141 1
Error 17 error C2065: 'value_type' : undeclared identifier glm\gtc\quaternion.inl 149 1
Warning 18 warning C4346: 'glm::detail::tquat::*=' : dependent name is not a type glm\gtc\quaternion.inl 149 1
Error 19 error C2143: syntax error : missing ')' before 'const' glm\gtc\quaternion.inl 149 1
Error 20 error C2039: '*=' : is not a member of 'glm::detail::tquat' glm\gtc\quaternion.inl 149 1
I don't know if I'm missing something or not but generally I just included the header files and included #include glm/gtc/type_ptr.hpp since I need the glm::value_ptr to get the pointer to the matrices.
I get another error in the rotate functionality which uses detail::tmat4x4 Rotate(detail::tmat4x4::null);
but it seems that it cant find detail::tmat4x4::null ... I'm new to C++.
The text was updated successfully, but these errors were encountered: