sdl2dll
Loading...
Searching...
No Matches
sdl::Texture Class Reference

Clase que encapsula una única textura. More...

#include <sdl_texture.h>

Public Member Functions

EXPORT Texture (Renderer &render, std::string file)
 Constructor.
 
EXPORT ~Texture ()
 Destructor.
 
EXPORT SDL_Texture * Get ()
 Obtiene un puntero a la estructura SDL_Texture.
 
EXPORT operator SDL_Texture * ()
 Obtiene un puntero a la estructura SDL_Texture.
 
EXPORT void Draw (Point punto)
 Traslada la textura al punto indicado.
 

Protected Attributes

Rendererrenderer
 
SDL_Texture * texture
 
Rect rect
 

Detailed Description

Clase que encapsula una única textura.

Constructor & Destructor Documentation

◆ Texture()

EXPORT sdl::Texture::Texture ( Renderer & render,
std::string file )
inline

Constructor.

Parameters
renderRenderer& contexto de renderizado
filestring ruta del fichero que contiene el gráfico de la textura

◆ ~Texture()

EXPORT sdl::Texture::~Texture ( )
inline

Destructor.

Destruye la textura especificada.

Member Function Documentation

◆ Draw()

EXPORT void sdl::Texture::Draw ( Point punto)
inline

Traslada la textura al punto indicado.

Parameters
puntoPoint punto de destino

Member Data Documentation

◆ rect

Rect sdl::Texture::rect
protected

Rectángulo que contiene la anchura y altura de la textura

◆ renderer

Renderer& sdl::Texture::renderer
protected

Referencia de contexto de renderizado

◆ texture

SDL_Texture* sdl::Texture::texture
protected

Una estructura opaca que contiene una representación eficiente y específica del controlador de los datos de píxeles.


The documentation for this class was generated from the following file: