![]()  | 
  
    Gamedev Framework (gf)
    0.7.0
    
   A C++14 framework for 2D games 
   | 
 
A texture with a single alpha channel. More...
#include <gf/Texture.h>

Public Member Functions | |
| AlphaTexture () | |
| Constructor.  More... | |
| bool | create (Vector2u size) | 
| Create the texture.  More... | |
  Public Member Functions inherited from gf::BareTexture | |
| BareTexture (Format format) | |
| Constructor.  More... | |
| ~BareTexture () | |
| Destructor.  More... | |
| BareTexture (const BareTexture &)=delete | |
| Deleted copy constructor.  More... | |
| BareTexture & | operator= (const BareTexture &)=delete | 
| Deleted copy assignment.  More... | |
| BareTexture (BareTexture &&other) noexcept | |
| Move constructor.  More... | |
| BareTexture & | operator= (BareTexture &&other) noexcept | 
| Move assignment.  More... | |
| Format | getFormat () const | 
| Get the format of the texture.  More... | |
| unsigned | getName () const | 
| Get the internal representation of the texture.  More... | |
| Vector2u | getSize () const | 
| Return the size of the texture.  More... | |
| void | setSmooth (bool smooth=true) | 
| Enable or disable the smooth filter.  More... | |
| bool | isSmooth () const noexcept | 
| Check if the smooth filter is enabled or not.  More... | |
| void | setRepeated (bool repeated=true) | 
| Enable or disable repeating.  More... | |
| bool | isRepeated () const noexcept | 
| Check if the texture is repeated or not.  More... | |
| void | update (const uint8_t *data) | 
| Update the whole texture from an array of pixels.  More... | |
| void | update (const uint8_t *data, const RectU &rect) | 
| Update a part of the texture from an array of pixels.  More... | |
| RectF | computeTextureCoords (const RectU &rect) const | 
| Compute normalized texture coordinates.  More... | |
| bool | generateMipmap () | 
| Generate a mipmap using the current texture data.  More... | |
Additional Inherited Members | |
  Public Types inherited from gf::BareTexture | |
| enum | Format {  Format::Color, Format::Alpha }  | 
| Format of the texture.  More... | |
  Static Public Member Functions inherited from gf::BareTexture | |
| static void | bind (const BareTexture *texture) | 
| Bind a texture for rendering.  More... | |
  Protected Member Functions inherited from gf::BareTexture | |
| bool | create (Vector2u size, const uint8_t *data) | 
| Create the texture.  More... | |
A texture with a single alpha channel.
This texture is used internally by gf::Font
| gf::AlphaTexture::AlphaTexture | ( | ) | 
Constructor.
No texture is created
| bool gf::AlphaTexture::create | ( | Vector2u | size | ) | 
Create the texture.
If this function fails, the texture is left unchanged.
| size | Size of the texture | 
 1.8.13