Closed ryanbartley closed 7 years ago
So, it looks like it couldn't find libcpprest...I updated it to look for 2.8, which is the one I had to install. Yet the problem above still existed. I removed the appendCode( const utility::char_t...) from .h and .cpp, which is probably not correct but it continued to build after that and now I'm getting these errors...
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Material.cpp:305:71: error: non-const lvalue reference to
type 'fbxsdk_2015_1::FbxProperty' cannot bind to a temporary of type 'fbxsdk_2015_1::FbxProperty'
pPhongSurface->TransparencyFactor, pPhongSurface->TransparentColor, pPhongSurface->FindProperty ("Opacity"),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Material.cpp:190:91: note: passing argument to parameter
'propertyOpaque' here
FbxPropertyT<FbxDouble> &property, FbxPropertyT<FbxDouble3> &propertyColor, FbxProperty &propertyOpaque,
^
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Material.cpp:340:75: error: non-const lvalue reference to
type 'fbxsdk_2015_1::FbxProperty' cannot bind to a temporary of type 'fbxsdk_2015_1::FbxProperty'
...pLambertSurface->TransparencyFactor, pLambertSurface->TransparentColor, pLambertSurface->FindProperty ("Opacity"),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Material.cpp:190:91: note: passing argument to parameter
'propertyOpaque' here
FbxPropertyT<FbxDouble> &property, FbxPropertyT<FbxDouble3> &propertyColor, FbxProperty &propertyOpaque,
^
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/glslShader.cpp:514:90: error: cannot pass object of non-trivial type
'utility::string_t' (aka 'basic_string<char, char_traits<char>, allocator<char> >') through variadic method; call will
abort at runtime [-Wnon-pod-varargs]
..._fragmentShader.appendCode (U("if ( cosAngle > cos (radians (u_%s * 0.5)) ) {\n"), szLightFallOffAngle) ;
^
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/glslShader.cpp:515:90: error: cannot pass object of non-trivial type
'utility::string_t' (aka 'basic_string<char, char_traits<char>, allocator<char> >') through variadic method; call will
abort at runtime [-Wnon-pod-varargs]
..._fragmentShader.appendCode (U("attenuation *=max (0., pow (cosAngle, u_%s)) ;\n"), szLightFallOffExponent) ;
^
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Material.cpp:369:34: error: non-const lvalue reference to
type 'fbxsdk_2015_1::FbxProperty' cannot bind to a temporary of type 'fbxsdk_2015_1::FbxProperty'
factorProperty, colorProperty, pMaterial->FindProperty ("Opacity"),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Material.cpp:190:91: note: passing argument to parameter
'propertyOpaque' here
FbxPropertyT<FbxDouble> &property, FbxPropertyT<FbxDouble3> &propertyColor, FbxProperty &propertyOpaque,
^
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Material.cpp:404:34: error: non-const lvalue reference to
type 'fbxsdk_2015_1::FbxProperty' cannot bind to a temporary of type 'fbxsdk_2015_1::FbxProperty'
factorProperty, colorProperty, pMaterial->FindProperty ("Opacity"),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Material.cpp:190:91: note: passing argument to parameter
'propertyOpaque' here
FbxPropertyT<FbxDouble> &property, FbxPropertyT<FbxDouble3> &propertyColor, FbxProperty &propertyOpaque,
^
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Material.cpp:448:34: error: non-const lvalue reference to
type 'fbxsdk_2015_1::FbxProperty' cannot bind to a temporary of type 'fbxsdk_2015_1::FbxProperty'
factorProperty, colorProperty, pMaterial->FindProperty ("Opacity"),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Material.cpp:190:91: note: passing argument to parameter
'propertyOpaque' here
FbxPropertyT<FbxDouble> &property, FbxPropertyT<FbxDouble3> &propertyColor, FbxProperty &propertyOpaque,
^
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Shaders.cpp:80:50: error: use of undeclared identifier
'fileName'
shaderFilename =FbxPathUtils::GetFolderName (fileName) + "/" + shaderFilename ;
^
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Shaders.cpp:84:23: error: cannot initialize a parameter of
type 'const char_type *' (aka 'const wchar_t *') with an rvalue of type 'const value_type *' (aka 'const char *')
shaderFile.write (tech.vertexShader ().source ().c_str (), tech.vertexShader ().source ()...
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../include/c++/v1/ostream:212:43: note:
passing argument to parameter '__s' here
basic_ostream& write(const char_type* __s, streamsize __n);
^
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Shaders.cpp:93:50: error: use of undeclared identifier
'fileName'
shaderFilename =FbxPathUtils::GetFolderName (fileName) + "/" + shaderFilename ;
^
/Users/ryanbartley/Documents/glTF/FBX2GLTF/FBX-glTF/IO-glTF/gltfWriter-Shaders.cpp:97:23: error: cannot initialize a parameter of
type 'const char_type *' (aka 'const wchar_t *') with an rvalue of type 'const value_type *' (aka 'const char *')
shaderFile.write (tech.fragmentShader ().source ().c_str (), tech.fragmentShader ().sourc...
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../include/c++/v1/ostream:212:43: note:
passing argument to parameter '__s' here
basic_ostream& write(const char_type* __s, streamsize __n);
Any help with these build problems would be greatly appreciated.
I'm having the exact problem as @ryanbartley. So if anyone knows how to get through this we'll be both very pleased !! Here is the output of my make command after I updated the libcpprest path to 2.8 :
[ 3%] Building CXX object IO-glTF/CMakeFiles/IO-glTF.dir/glslShader.cpp.o
In file included from /Applications/FBX-glTF/IO-glTF/glslShader.cpp:22:
/Applications/FBX-glTF/IO-glTF/glslShader.h:51:7: error: class member cannot be
redeclared
void appendCode (const utility::char_t *format, ...) ;
^
/Applications/FBX-glTF/IO-glTF/glslShader.h:50:7: note: previous declaration is
here
void appendCode (const char *format, ...) ;
^
/Applications/FBX-glTF/IO-glTF/glslShader.cpp:96:18: error: redefinition of
'appendCode'
void glslShader::appendCode (const utility::char_t *format, ...) {
^
/Applications/FBX-glTF/IO-glTF/glslShader.cpp:83:18: note: previous definition
is here
void glslShader::appendCode (const char *format, ...) {
^
2 errors generated.
make[2]: *** [IO-glTF/CMakeFiles/IO-glTF.dir/glslShader.cpp.o] Error 1
make[1]: *** [IO-glTF/CMakeFiles/IO-glTF.dir/all] Error 2
make: *** [all] Error 2
Same problem for me too, unfortunately. Same output as @ryanbartley and @jazone. Would love to know the solution if there is one.
Anybody found a solution for that issue?
Having the same problem here.
Is this project closed? Would you be willing to take a PR replacing the enormous dependency of Casablanca AKA C++REST with a simple header only json engine?
@cyrillef @ryanbartley that's a good idea -
Preliminary work of swapping out the json engine can be found here. Tested and working on OSX. Need to update windows and linux, which I can do this week.
Hi,
I am extremely sorry for the delay. The build issue has been fixed in 'dev' branch.
Thanks, Vijaya Praaksh.
Building on Mac OSX, I've run into this error...