27 lines
500 B
C++
27 lines
500 B
C++
#ifndef GUI_IMAGE_HPP
|
|
#define GUI_IMAGE_HPP
|
|
|
|
|
|
#include <FL/fl_types.h>
|
|
#include <FL/Fl_Widget.H>
|
|
|
|
/** The constructor of the image class, get additional
|
|
* @param x: The mouse-position on the x-axis.
|
|
* @param y: The mouse-position on the y-axis:
|
|
* @param w: The width of a single pixel,
|
|
* @param h: The height of a single pixel.
|
|
*/
|
|
|
|
class Image : public Fl_Widget {
|
|
uchar *buf;
|
|
|
|
public:
|
|
Image(int x, int y, int w, int h);
|
|
|
|
void draw() override;
|
|
|
|
void getPixels();
|
|
};
|
|
|
|
#endif
|