.. index:: pair: class; EE::Graphics::TextureDrawable .. _doxid-class_e_e_1_1_graphics_1_1_texture_drawable: class EE::Graphics::TextureDrawable =================================== .. toctree:: :hidden: Overview ~~~~~~~~ Per-consumer drawable state backed by a shared texture resource. :ref:`More...` .. ref-code-block:: cpp :class: doxyrest-overview-code-block #include class TextureDrawable: public :ref:`EE::Graphics::DrawableResource` { public: // construction :target:`TextureDrawable`(:ref:`TexturePtr` texture); // methods static :ref:`TextureDrawablePtr` :target:`New`(:ref:`TexturePtr` texture); virtual :ref:`Sizef` :target:`getSize`(); virtual :ref:`Sizef` :target:`getPixelsSize`(); virtual void :target:`draw`(); virtual void :target:`draw`(const :ref:`Vector2f`& position); virtual void :target:`draw`(const :ref:`Vector2f`& position, const :ref:`Sizef`& size); virtual bool :target:`isStateful`(); virtual :ref:`DrawablePtr` :ref:`clone`() const; const :ref:`TexturePtr`& :target:`getTexture`() const; }; Inherited Members ----------------- .. ref-code-block:: cpp :class: doxyrest-overview-inherited-code-block public: // typedefs typedef :ref:`DrawableResourceCallbackState::Callback` :ref:`OnResourceChangeCallback`; // enums enum :ref:`Type`; // methods virtual :ref:`Sizef` :ref:`getSize`() = 0; virtual :ref:`Sizef` :ref:`getPixelsSize`() = 0; virtual :ref:`Float` :ref:`getMinIntrinsicWidth`(); virtual :ref:`Float` :ref:`getMaxIntrinsicWidth`(); virtual void :ref:`draw`() = 0; virtual void :ref:`draw`(const :ref:`Vector2f`& position) = 0; virtual void :ref:`draw`(const :ref:`Vector2f`& position, const :ref:`Sizef`& size) = 0; virtual bool :ref:`isStateful`() = 0; virtual :ref:`DrawablePtr` :ref:`clone`() const; void :ref:`setAlpha`(:ref:`Uint8` alpha); const :ref:`Uint8`& :ref:`getAlpha`(); void :ref:`setColor`(const :ref:`Color`& color); const :ref:`Color`& :ref:`getColor`() const; void :ref:`setColorFilter`(const :ref:`Color`& color); :ref:`RGB` :ref:`getColorFilter`(); void :ref:`clearColor`(); void :ref:`clearColorFilter`(); void :ref:`resetAlpha`(); :ref:`Type` :ref:`getDrawableType`() const; const :ref:`Vector2f`& :ref:`getPosition`() const; void :ref:`setPosition`(const :ref:`Vector2f`& position); virtual bool :ref:`isDrawableResource`() const; const :ref:`String::HashType`& :ref:`getId`() const; const std::string :ref:`getName`() const; void :ref:`setName`(const std::string& name); virtual bool :ref:`isDrawableResource`() const; :ref:`DrawableResourceConnection` :ref:`connectResourceChange`(:ref:`OnResourceChangeCallback` cb); .. _details-class_e_e_1_1_graphics_1_1_texture_drawable: Detailed Documentation ~~~~~~~~~~~~~~~~~~~~~~ Per-consumer drawable state backed by a shared texture resource. Methods ------- .. index:: pair: function; clone .. _doxid-class_e_e_1_1_graphics_1_1_texture_drawable_1ae0afb36f6a32f56699e4bdb5d4ed3902: .. ref-code-block:: cpp :class: doxyrest-title-code-block virtual :ref:`DrawablePtr` clone() const Creates an independently mutable instance backed by the same immutable resource data. This is an ownership/setup operation; rendering loops must retain and reuse the result.