< index < 5. Image toolkit |
===================================== |
C++ : TCODColor TCODImage::getMipmapPixel(float x0,float y0, float x1, float y1) C : TCOD_color_t TCOD_image_get_mipmap_pixel(TCOD_image_t image,float x0,float y0, float x1, float y1) Py : image_get_mipmap_pixel(image,x0,y0, x1, y1)
Parameter | Description |
---|---|
image | In the C version, the image handler, obtained with the load function. |
x0,y0 | Coordinates in pixels of the upper-left corner of the region. 0.0 <= x0 < x1 0.0 <= y0 < y1 |
x1,y1 | Coordinates in pixels of the lower-right corner of the region. x0 < x1 < width y0 < y1 < height |
C++ : TCODImage *pix = new TCODImage(80,50); TCODColor col=pix->getMipMapPixel(37.5f, 22.5f, 42.5f, 28.5f); C : TCOD_image_t pix = TCOD_image_new(80,50); TCOD_color_t col=TCOD_image_get_mipmap_pixel(pix,37.5f, 22.5f, 42.5f, 28.5f); Py : pix = libtcod.image_new(80,50) col=libtcod.image_get_mipmap_pixel(pix,37.5, 22.5, 42.5, 28.5)