BVB Source Codes

CRYENGINE Show ControllerTCB.h Source code

Return Download CRYENGINE: download ControllerTCB.h Source code - Download CRYENGINE Source code - Type:.h
  1. // Copyright 2001-2016 Crytek GmbH / Crytek Group. All rights reserved.
  2.  
  3. #pragma once
  4.  
  5. #include <CryMath/TCBSpline.h>
  6.  
  7. // CJoint animation.
  8. struct CControllerTCB : public IController
  9. {
  10.         size_t SizeOfController() const
  11.         {
  12.                 return sizeof(CControllerTCB) + m_posTrack.sizeofThis() + m_rotTrack.sizeofThis() + m_sclTrack.sizeofThis();
  13.         }
  14.  
  15.         size_t ApproximateSizeOfThis() const
  16.         {
  17.                 return SizeOfController();
  18.         }
  19.  
  20.         JointState     GetOPS(f32 key, Quat& rot, Vec3& pos, Diag33& scl) const;
  21.         JointState     GetOP(f32 key, Quat& rot, Vec3& pos) const;
  22.         JointState     GetO(f32 key, Quat& rot) const;
  23.         JointState     GetP(f32 key, Vec3& pos) const;
  24.         JointState     GetS(f32 key, Diag33& scl) const;
  25.  
  26.         virtual size_t GetRotationKeysNum() const
  27.         {
  28.                 return 0;
  29.         }
  30.  
  31.         virtual size_t GetPositionKeysNum() const
  32.         {
  33.                 return 0;
  34.         }
  35.  
  36.         virtual size_t GetScaleKeysNum() const
  37.         {
  38.                 return 0;
  39.         }
  40.  
  41.         JointState                 m_active;
  42.         spline::TCBSpline<Vec3>    m_posTrack;
  43.         spline::TCBAngleAxisSpline m_rotTrack;
  44.         spline::TCBSpline<Vec3>    m_sclTrack;
  45.  
  46.         CControllerTCB()
  47.         {
  48.                 m_nControllerId = 0xaaaa5555;
  49.         }
  50.  
  51.         void GetMemoryUsage(ICrySizer* pSizer) const
  52.         {
  53.                 pSizer->AddObject(this, sizeof(*this));
  54.                 pSizer->AddObject(m_posTrack);
  55.                 pSizer->AddObject(m_rotTrack);
  56.                 pSizer->AddObject(m_sclTrack);
  57.         }
  58. };
  59.  
downloadControllerTCB.h Source code - Download CRYENGINE Source code
Related Source Codes/Software:
postal - 2017-06-11
reactide - Reactide is the first dedicated IDE for React web ... 2017-06-11
rkt - rkt is a pod-native container engine for Linux. It... 2017-06-11
uWebSockets - Tiny WebSockets https://for... 2017-06-11
realworld - TodoMVC for the RealWorld - Exemplary fullstack Me... 2017-06-11
CRYENGINE - CRYENGINE is a powerful real-time game development... 2017-06-11
goreplay - GoReplay is an open-source tool for capturing and ... 2017-06-10
pyenv - Simple Python version management 2017-06-10
redux-saga - An alternative side effect model for Redux apps ... 2017-06-10
angular-starter - 2017-06-10

 Back to top