daily pastebin goal
12%
SHARE
TWEET

Untitled

a guest May 30th, 2017 54 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include "stdafx.h"
  2. #include <fbxsdk.h>
  3. #include "FBXWrapper.h"
  4. #include "FBXUtils.h"
  5.  
  6. #ifdef IOS_REF
  7. #undef  IOS_REF
  8. #define IOS_REF (*(pManager->GetIOSettings()))
  9. #endif
  10.  
  11. using namespace System::Runtime::InteropServices;
  12.  
  13. FBXWrapper::FBXVector4::FBXVector4(double x, double y, double z, double w)
  14. {
  15.    vector = new FbxVector4(x, y, z, w);
  16. }
  17.  
  18. FBXWrapper::FBXVector4::FBXVector4()
  19. {
  20.    vector = new FbxVector4(0, 0, 0, 0);
  21. }
  22.  
  23. FBXWrapper::FBXVector4::FBXVector4(FbxVector4 v)
  24. {
  25.    vector = &v;
  26. }
  27.  
  28. FBXWrapper::FBXAMatrix::FBXAMatrix()
  29. {
  30.    mat = new FbxAMatrix();
  31. }
  32.  
  33. FBXWrapper::FBXVector4^ FBXWrapper::FBXAMatrix::getR()
  34. {
  35.    return gcnew FBXVector4(mat->GetR());
  36. }
  37.  
  38. void FBXWrapper::FBXAMatrix::SetRow(int Y, FBXVector4^ row)
  39. {
  40.    mat->SetRow(Y, *row->vector);
  41. }
  42.  
  43. FBXWrapper::FBXNode::FBXNode(FbxNode* n)
  44. {
  45.     node = n;
  46. }
  47.  
  48. FBXWrapper::FBXNode^ FBXWrapper::FBXNode::FindChild(String^ name)
  49. {
  50.     IntPtr ptrToNativeString = Marshal::StringToHGlobalAnsi(name);
  51.     const char* lBoneName = static_cast<char*>(ptrToNativeString.ToPointer());
  52.     FBXNode^ result = gcnew FBXNode(node->FindChild(lBoneName));   
  53.     Marshal::FreeHGlobal(ptrToNativeString);
  54.     return result;
  55. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top