1 /*---------------------------------------------------------------------------* 2 Project: NintendoWare 3 File: gfx_ParticleSceneUpdater.h 4 5 Copyright (C)2009-2010 Nintendo Co., Ltd./HAL Laboratory, Inc. All rights reserved. 6 7 These coded instructions, statements, and computer programs contain 8 proprietary information of Nintendo of America Inc. and/or Nintendo 9 Company Ltd., and are protected by Federal copyright law. They may 10 not be disclosed to third parties or copied or duplicated in any form, 11 in whole or in part, without the prior written consent of Nintendo. 12 13 $Revision: 19597 $ 14 *---------------------------------------------------------------------------*/ 15 16 #ifndef NW_GFX_PARTICLESCENEUPDATER_H_ 17 #define NW_GFX_PARTICLESCENEUPDATER_H_ 18 19 #include <nw/gfx/gfx_ISceneUpdater.h> 20 #include <nw/gfx/gfx_SkeletonUpdater.h> 21 #include <nw/gfx/gfx_WorldMatrixUpdater.h> 22 #include <nw/gfx/gfx_BillboardUpdater.h> 23 24 namespace nw 25 { 26 namespace gfx 27 { 28 29 class SceneContext; 30 class ParticleContext; 31 class ParticleSet; 32 33 //--------------------------------------------------------------------------- 34 //! @brief パーティクルの更新を行うためのクラスです(仮)。 35 //--------------------------------------------------------------------------- 36 class ParticleSceneUpdater : public GfxObject 37 { 38 private: 39 NW_DISALLOW_COPY_AND_ASSIGN(ParticleSceneUpdater); 40 41 public: 42 NW_UT_RUNTIME_TYPEINFO; 43 44 //! シーンノードの MoveArray の定義です。 45 typedef ut::MoveArray<SceneNode*> SceneNodeArray; 46 47 //! ParticleSetの MoveArray の定義です。 48 typedef ut::MoveArray<ParticleSet*> ParticleSetArray; 49 50 //---------------------------------------- 51 //! @name 作成 52 //@{ 53 54 //! パーティクルシーンアップデータクラスを構築するためのクラスです。 55 class Builder 56 { 57 public: 58 //! @brief コンストラクタです。 Builder()59 Builder() {} 60 61 //! @brief シーンアップデータを生成します。 62 //! 63 //! @param[in] allocator 64 //! 65 //! @return 生成したシーンアップデータを返します。 66 //! 67 ParticleSceneUpdater* Create(os::IAllocator* allocator); 68 }; 69 70 //@} 71 72 //---------------------------------------- 73 //! @name 更新 74 //@{ 75 76 //! @brief シーンコンテキストをビューに基づいて更新します。 77 //! 78 //! @param[in] sceneContext シーンコンテキストです。 79 //! @param[in] particleContext パーティクルシーンコンテキストです。 80 //! 81 virtual void UpdateNode( 82 SceneContext* sceneContext, 83 ParticleContext* particleContext); 84 85 //! @brief バッファを交換します。 86 //! 87 //! @param[in] sceneContext シーンコンテキストです。 88 //! SwapBuffer(SceneContext *)89 virtual void SwapBuffer(SceneContext* /*sceneContext*/) {} 90 91 //@} 92 93 protected: 94 //---------------------------------------- 95 //! @name コンストラクタ/デストラクタ 96 //@{ 97 98 //! コンストラクタです。 ParticleSceneUpdater(os::IAllocator * allocator)99 ParticleSceneUpdater(os::IAllocator* allocator) 100 : GfxObject(allocator) 101 {} 102 103 //! デストラクタです。 ~ParticleSceneUpdater()104 virtual ~ParticleSceneUpdater() {} 105 106 //@} 107 }; 108 109 } // namespace gfx 110 } // namespace nw 111 112 #endif // NW_GFX_SCENEUPDATER_H_ 113