5#ifndef DCPP_I_GUI_IMAGE_HPP_INCLUDED
6#define DCPP_I_GUI_IMAGE_HPP_INCLUDED
8#include <duckcpp/core/engine/IGUIElement.hpp>
Base class of all GUI elements.
Definition IGUIElement.hpp:24
virtual void draw()
Draws the element and its children.
Definition IGUIElement.hpp:331
GUI Environment. Used as factory and manager of all other GUI elements.
Definition IGUIEnvironment.hpp:73
GUI element displaying an image.
Definition IGUIImage.hpp:20
virtual void setDrawBounds(const dcpp::nub::rectf &drawBoundUVs=dcpp::nub::rectf(0.f, 0.f, 1.f, 1.f))=0
Restrict drawing-area.
virtual dcpp::nub::recti getSourceRect() const =0
Returns the customized source rectangle of the image to be used.
virtual void setUseAlphaChannel(bool use)=0
Sets if the image should use its alpha channel to draw itself.
virtual bool isDrawBackgroundEnabled() const =0
Checks if a background is drawn when no texture is set.
IGUIImage(IGUIEnvironment *environment, IGUIElement *parent, dcpp::int32_kt id, dcpp::nub::recti rectangle)
constructor
Definition IGUIImage.hpp:24
virtual dcpp::video::ITexture * getImage() const =0
Gets the image texture.
virtual void setSourceRect(const dcpp::nub::recti &sourceRect)=0
Sets the source rectangle of the image. By default the full image is used.
virtual bool isAlphaChannelUsed() const =0
Returns true if the image is using the alpha channel, false if not.
virtual dcpp::nub::rectf getDrawBounds() const =0
Get drawing-area restrictions.
virtual bool isImageScaled() const =0
Returns true if the image is scaled to fit, false if not.
virtual void setScaleImage(bool scale)=0
Sets if the image should scale to fit the element.
virtual dcpp::video::SColor getColor() const =0
Gets the color of the image.
virtual void setImage(dcpp::video::ITexture *image)=0
Sets an image texture.
virtual void setDrawBackground(bool draw)=0
Sets whether to draw a background color (EGDC_3D_DARK_SHADOW) when no texture is set.
virtual void setColor(dcpp::video::SColor color)=0
Sets the color of the image.
Axis aligned bounding box in 3d dimensional space.
Definition aabbox3d.hpp:22
Rectangle template.
Definition rect.hpp:27
Interface of a Video Driver dependent Texture.
Definition ITexture.hpp:186
Class representing a 32 bit ARGB color.
Definition SColor.hpp:317
@ EGUIET_IMAGE
An image (IGUIImage)
Definition EGUIElementTypes.hpp:47
As of Duckcpp 1.6, position2d is a synonym for vector2d.
Definition shared_device.hpp:34
signed int int32_kt
32 bit signed variable.
Definition irrTypes.hpp:72