1 #ifndef __DALI_INTERNAL_RENDERABLE_ACTOR_H__
2 #define __DALI_INTERNAL_RENDERABLE_ACTOR_H__
5 * Copyright (c) 2014 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.
22 #include <dali/public-api/actors/renderable-actor.h>
23 #include <dali/public-api/common/dali-common.h>
24 #include <dali/internal/event/actors/actor-impl.h>
25 #include <dali/internal/event/effects/shader-declarations.h>
33 class RenderableAttachment;
36 * An abstract base class for renderable actors
38 class RenderableActor : public Actor
42 * Protected constructor; only derived classes are instantiatable.
47 * A reference counted object may only be deleted by calling Unreference()
49 virtual ~RenderableActor();
54 * @return a reference to the renderable attachment
56 virtual RenderableAttachment& GetRenderableAttachment() const = 0;
59 RenderableActor(const RenderableActor&);
61 RenderableActor& operator=(const RenderableActor& rhs);
65 } // namespace Internal
67 // Helpers for public-api forwarding methods
69 inline Internal::RenderableActor& GetImplementation(Dali::RenderableActor& renderable)
71 DALI_ASSERT_ALWAYS( renderable && "RenderableActor handle is empty" );
73 BaseObject& handle = renderable.GetBaseObject();
75 return static_cast<Internal::RenderableActor&>(handle);
78 inline const Internal::RenderableActor& GetImplementation(const Dali::RenderableActor& renderable)
80 DALI_ASSERT_ALWAYS(renderable && "RenderableActor handle is empty" );
82 const BaseObject& handle = renderable.GetBaseObject();
84 return static_cast<const Internal::RenderableActor&>(handle);
89 #endif // __DALI_INTERNAL_RENDERABLE_ACTOR_H__