#ifndef Bild_H #define Bild_H #include "Array.h" #include "Objekt.h" namespace Framework { class Farbe; // Farbe.h class Text; // Text.h class Punkt; // Punkt.h class LRahmen; // Rahmen.h struct MausEreignis; // Mausereignis.h class Bild; // aus dieser Datei class Bild { private: int *fc; Punkt *größe; Text *pfad; int ref; TArray< Punkt > *dPosA; TArray< Punkt > *dGrößeA; CRITICAL_SECTION threadSave; public: // Konstruktor Bild(); // Destruktor ~Bild(); // nicht constant void lock(); void unlock(); void neuBild( Punkt *größe, Farbe *füllFarbe ); // erzeugt ein neues Bild mit der Größe größe und der Hintergrundfarbe füllFarbe void setPixel( Punkt *p, Farbe *f ); // setzt die Farbe eines bestimmten Pixels void alphaPixel( Punkt *p, Farbe *f ); void alphaPixel( int x, int y, int f ); void alphaPixel( int i, int f ); // setzt die Farbe eines bestimmten Pixels void füllRegion( Punkt *p, Punkt *gr, Farbe *f ); // setzt die Farbe einer bestimmten Region void füllRegion( int x, int y, int b, int h, int fc ); void alphaRegion( int x, int y, int b, int h, int fc ); void drawLinie( Punkt *pos, Punkt *pos2, Farbe *f ); // zeichnet eine Linie von pos zu pos2 void drawLinieAlpha( Punkt *pos, Punkt *pos2, Farbe *f ); // zeichnet eine Linie von pos zu pos2 void drawLinieH( Punkt *pos, int län, Farbe *f ); // zeichnet eine horizontale Linie void drawLinieV( Punkt *pos, int län, Farbe *f ); // zeichnet eine vertikale Linie void drawLinieH( int x, int y, int län, int fc ); // zeichnet eine horizontale Linie void drawLinieV( int x, int y, int län, int fc ); // zeichnet eine vertikale Linie void drawLinieHAlpha( Punkt *pos, int län, Farbe *f ); // zeichnet eine horizontale Linie void drawLinieVAlpha( Punkt *pos, int län, Farbe *f ); // zeichnet eine vertikale Linie void drawLinieHAlpha( int x, int y, int län, int fc ); // zeichnet eine horizontale Linie void drawLinieVAlpha( int x, int y, int län, int fc ); // zeichnet eine vertikale Linie void drawLinie( Punkt *pos1, Punkt *pos2, int län, Farbe *f ); // Zeichnet eine Linie von pos1 bis pos2 mit länge län void drawLinie( int x1, int y1, int x2, int y2, int fc ); // zeichnet eine Linie von Punkt( x1, y1 ) nach Punke( x2, y2 ) void Bild::drawLinieAlpha( int x1, int y1, int x2, int y2, int fc ); void setDrawOptions( int x, int y, int xb, int yh ); // setzt die Drawoptionen void drawBild( int x, int y, int br, int hö, Bild *zBild ); // zeichet zBild void alphaBild( int x, int y, int br, int hö, Bild *zBild ); // constant int *getBuffer()const; // gibt buffer zurück Farbe *getPixel( Punkt *p ) const; // gibt die Farbe des Pixels(x, y) zurück Punkt *getGröße() const; // gibt die Größe zurück int getBreite() const; // gibt die Breite zurück int getHöhe() const; // gibt die Höhe zurück int getDOX() const; int getDOY() const; int getDOBX() const; int getDOHY() const; // Reference Counting Bild *getThis(); Bild *release(); }; } #endif