GteBillboardNode.h
Go to the documentation of this file.
1 // David Eberly, Geometric Tools, Redmond WA 98052
2 // Copyright (c) 1998-2017
3 // Distributed under the Boost Software License, Version 1.0.
4 // http://www.boost.org/LICENSE_1_0.txt
5 // http://www.geometrictools.com/License/Boost/LICENSE_1_0.txt
6 // File Version: 3.0.0 (2016/06/19)
7 
8 #pragma once
9 
10 #include <Graphics/GteNode.h>
11 
12 namespace gte
13 {
14 
16 {
17 public:
18  // The model space of the billboard has an up vector of (0,1,0) that is
19  // chosen to be the billboard's axis of rotation.
20 
21  // Construction.
22  BillboardNode(std::shared_ptr<Camera> const& camera);
23 
24  // The camera to which the billboard is aligned.
25  inline void AlignTo(std::shared_ptr<Camera> const& camera);
26 
27 protected:
28  // Support for the geometric update.
29  virtual void UpdateWorldData(double applicationTime);
30 
31  std::shared_ptr<Camera> mCamera;
32 };
33 
34 
35 inline void BillboardNode::AlignTo(std::shared_ptr<Camera> const& camera)
36 {
37  mCamera = camera;
38 }
39 
40 
41 }
std::shared_ptr< Camera > mCamera
#define GTE_IMPEXP
Definition: GTEngineDEF.h:63
void AlignTo(std::shared_ptr< Camera > const &camera)


geometric_tools_engine
Author(s): Yijiang Huang
autogenerated on Thu Jul 18 2019 03:59:59