| 22 | namespace doc { |
| 23 | |
| 24 | color_t get_pixel(const Image* image, int x, int y) |
| 25 | { |
| 26 | ASSERT(image); |
| 27 | |
| 28 | if ((x >= 0) && (y >= 0) && (x < image->width()) && (y < image->height())) |
| 29 | return image->getPixel(x, y); |
| 30 | else |
| 31 | return -1; |
| 32 | } |
| 33 | |
| 34 | void put_pixel(Image* image, int x, int y, color_t color) |
| 35 | { |