Draw in abstract units and scale to pixels at the end.
This commit is contained in:
parent
a561242395
commit
0c6275f41c
9 changed files with 73 additions and 22 deletions
|
@ -36,15 +36,15 @@ namespace cloonel {
|
|||
void Reload ( void );
|
||||
void Destroy ( void ) noexcept;
|
||||
bool IsLoaded ( void ) const { return nullptr != m_texture; }
|
||||
void Render ( int2 parPos ) const { Render(parPos, m_size); }
|
||||
void Render ( int2 parPos, ushort2 parSize ) const;
|
||||
void Render ( const float2& parPos ) const { Render(parPos, m_size); }
|
||||
void Render ( const float2& parPos, const float2& parSize ) const;
|
||||
const SDLMain* SDLObject ( void ) const { return m_sdlmain; }
|
||||
|
||||
private:
|
||||
const std::string m_path;
|
||||
float2 m_size;
|
||||
SDL_Texture* m_texture;
|
||||
SDLMain* const m_sdlmain;
|
||||
ushort2 m_size;
|
||||
};
|
||||
} //namespace cloonel
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue