My Project
Public Member Functions | List of all members
Asset Class Reference

Class containing all elements of an Asset. More...

#include <Asset.hpp>

Public Member Functions

 Asset (nlohmann::json const &jsonData)
 Construct a new Asset object. More...
 
 ~Asset ()
 Destroy the Asset object.
 
MyTexturegetTexture ()
 Get the Texture object. More...
 
float getScale () const
 Get the Scale object. More...
 
component::crect_t getRectangle () const
 Get the Rectangle object. More...
 
std::size_t getNbFrames () const
 Get the Nb Frames object. More...
 

Detailed Description

Class containing all elements of an Asset.

Constructor & Destructor Documentation

◆ Asset()

Asset::Asset ( nlohmann::json const &  jsonData)

Construct a new Asset object.

Parameters
jsonDatajson data to load asset

Member Function Documentation

◆ getNbFrames()

std::size_t Asset::getNbFrames ( ) const

Get the Nb Frames object.

Returns
std::size_t nb frames of the asset

◆ getRectangle()

component::crect_t Asset::getRectangle ( ) const

Get the Rectangle object.

Returns
component::crect_t Rectangle of the asset

◆ getScale()

float Asset::getScale ( ) const

Get the Scale object.

Returns
float Scale of the asset

◆ getTexture()

MyTexture & Asset::getTexture ( )

Get the Texture object.

Returns
MyTexture& Texture of the asset

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