Merge "Added API to generate a MeshData object for a Dali::Path object" into tizen
[platform/core/uifw/dali-core.git] / dali / public-api / actors / renderable-actor.h
index 85d0baa..9294453 100644 (file)
 
 // INTERNAL INCLUDES
 #include <dali/public-api/actors/actor.h>
+#include <dali/public-api/shader-effects/shader-effect.h>
 #include <dali/public-api/actors/blending.h>
 #include <dali/public-api/actors/sampling.h>
 
-namespace Dali DALI_IMPORT_API
+namespace Dali
 {
 namespace Internal DALI_INTERNAL
 {
@@ -77,9 +78,18 @@ public:
   ~RenderableActor();
 
   /**
-   * @copydoc Dali::BaseHandle::operator=
+   * @brief Copy constructor
+   *
+   * @param [in] copy The actor to copy.
+   */
+  RenderableActor(const RenderableActor& copy);
+
+  /**
+   * @brief Assignment operator
+   *
+   * @param [in] rhs The actor to copy.
    */
-  using BaseHandle::operator=;
+  RenderableActor& operator=(const RenderableActor& rhs);
 
   /**
    * @brief Allows modification of an actors position in the depth sort algorithm.
@@ -247,6 +257,33 @@ public:
    */
   void GetFilterMode( FilterMode::Type& minFilter, FilterMode::Type& magFilter) const;
 
+  /**
+   * @brief Sets the shader effect for the RenderableActor.
+   *
+   * Shader effects provide special effects like ripple and bend.
+   * Setting a shader effect removes any shader effect previously set by SetShaderEffect.
+   * @pre The actor has been initialized.
+   * @pre effect has been initialized.
+   * @param [in] effect The shader effect.
+   */
+  void SetShaderEffect( ShaderEffect effect );
+
+  /**
+   * @brief Retrieve the custom shader effect for the RenderableActor.
+   * If default shader is used an empty handle is returned.
+   *
+   * @pre The Actor has been initialized.
+   * @return The shader effect
+   */
+  ShaderEffect GetShaderEffect() const;
+
+  /**
+   * @brief Removes the current shader effect.
+   *
+   * @pre The Actor has been initialized.
+   */
+  void RemoveShaderEffect();
+
 public: // Not intended for application developers
 
   /**
@@ -257,6 +294,25 @@ public: // Not intended for application developers
   explicit DALI_INTERNAL RenderableActor(Internal::RenderableActor* actor);
 };
 
+/**
+ * @brief Sets the shader effect for all RenderableActors in a tree of Actors.
+ *
+ * @see RenderableActor::SetShaderEffect
+ *
+ * @param [in] actor root of a tree of actors.
+ * @param [in] effect The shader effect.
+ */
+DALI_IMPORT_API void SetShaderEffectRecursively( Actor actor, ShaderEffect effect );
+
+/**
+ * @brief Removes the shader effect from all RenderableActors in a tree of Actors.
+ *
+ * @see RenderableActor::RemoveShaderEffect
+ *
+ * @param [in] actor root of a tree of actors.
+ */
+DALI_IMPORT_API void RemoveShaderEffectRecursively( Actor actor );
+
 } // namespace Dali
 
 #endif // __DALI_RENDERABLE_ACTOR_H__