SUPER Space invader : Turbo edition DX - VS GOD 1.0.0
A simple space invader ripoff
idrawable.h
Go to the documentation of this file.
1
11#ifndef DRAWABLE_H
12#define DRAWABLE_H
13
14#include <memory>
15
16class MinGL;
17
22namespace nsGraphics
23{
24
30{
31
32public:
37 virtual ~IDrawable() = default;
38
43 virtual void draw(MinGL& window) const = 0;
44
51 friend MinGL& operator<<(MinGL& window, const IDrawable& drawable)
52 {
53 drawable.draw(window);
54
55 return window;
56 }
57
58}; // class IDrawable
59
60} // namespace nsGraphics
61
62#endif // DRAWABLE_H
Classe de base de minGL 2.
Definition: mingl.h:35
Interface pour un objet affichable.
Definition: idrawable.h:30
friend MinGL & operator<<(MinGL &window, const IDrawable &drawable)
Surcharge de l'opérateur d'injection.
Definition: idrawable.h:51
virtual ~IDrawable()=default
Destructeur pour la classe IDrawable.
virtual void draw(MinGL &window) const =0
Fonction pour afficher l'objet.
Espace de nom pour les utilitaires graphiques.
Definition: idrawable.h:16