5 * Copyright (c) 2016 Samsung Electronics Co., Ltd.
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
21 #include "game-renderer.h"
23 #include <dali/public-api/actors/actor.h>
26 * @brief The GameEntity class
27 * GameEntity wraps the Dali::Actor class and binds the GameRenderer with
28 * loaded entity. Entities are owned by the GameScene and populated when
29 * scene is being deserialized.
36 * Creates an instance of GameEntity with given name
37 * @param[in] name Name of created entity
39 GameEntity( const char* name );
42 * Destroys an instance of GameEntity
47 * Returns the GameRenderer object
49 GameRenderer& GetGameRenderer();
52 * Returns associated DALi actor
53 * @return Returns actor associated with this GameEntity
55 Dali::Actor& GetActor();
58 * Sets location of entity
59 * @param[in] location Local position of entity
61 void SetLocation( const Dali::Vector3& location );
64 * Sets rotation of entity
65 * @param[in] rotation Local rotation of entity
67 void SetRotation( const Dali::Quaternion& rotation );
70 * Sets scale of entity
71 * @param[in] scale Local scale of entity
73 void SetScale( const Dali::Vector3& scale );
77 * @param[in] size Bounding box of entity
79 void SetSize( const Dali::Vector3& size );
82 * Updates Dali::Renderer in case if anything changed ( geometry, texture, etc. )
84 void UpdateRenderer();
89 GameRenderer mGameRenderer;