|
XenevaOS
|


Go to the source code of this file.
Classes | |
| struct | _thumbox_ |
| struct | _glimparea_ |
Macros | |
| #define | __GLIPMSE_H__ |
| #define | THUMB_W 200 |
| #define | THUMB_H 200 |
Typedefs | |
| typedef struct _thumbox_ | thumbnail_t |
| typedef struct _glimparea_ | GlimpBox |
Functions | |
| void | GlimpseWindowPaint (ChWindow *win) |
| GlimpseWindowPaint – paint the glimpse window. | |
| void | compute_thumb_size (int src_w, int src_h, int max_w, int max_h, int *out_w, int *out_h) |
| compute_thumb_size – computes the best possible thumbnail size out of given image width and height | |
| void | thumbnail_box (ChCanvas *canvas, uint8_t *src, int src_w, int src_h, uint8_t *dst, int dst_x, int dst_y, int dst_w, int dst_h) |
| thumbnail_box – calculate and prepare the thumbnail using box_filter algorithm | |
| void | _Glimpse_draw_thumb (ChCanvas *canv, char *path, int dst_x, int dst_y, int max_w, int max_h) |
| _Glimpse_draw_thumb – load and draw thumbnail to canvas | |
| GlimpBox * | _Glimpse_create_glimbox (int xloc, int yloc, int width, int height) |
| thumbnail_t * | _Glimpse_create_thumbnail (int xloc, int yloc, int width, int height) |
| void | _Glimpse_add_thumbnail (GlimpBox *box, thumbnail_t *thumb) |
| _Glimpse_add_thumbnail – adds thumbnail box to glimpbox list | |
| void | _Glimpse_box_repaint (GlimpBox *box, ChWindow *win) |
| _Glimpse_box_repaint – repaint glimpse area | |
| GlimpBox * | _Glimpse_get_main_glimp () |
| _Glimpse_get_main_glimp – return main glimp area | |
| #define __GLIPMSE_H__ |
BSD 2-Clause License
Copyright (c) 2022, Manas Kamal Choudhury All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
| #define THUMB_H 200 |
| #define THUMB_W 200 |
| typedef struct _glimparea_ GlimpBox |
| typedef struct _thumbox_ thumbnail_t |
|
extern |
_Glimpse_add_thumbnail – adds thumbnail box to glimpbox list
| box | – Pointer to glimpse box |
| thumb | – pointer to thumnail data |
_Glimpse_box_repaint – repaint glimpse area
| box | – Pointer to glimps box |
| win | – Pointer to main window |
|
extern |
_Glimpse_create_glimbox – creates a glimbox bounding area
| xloc | – x location within glimpse |
| yloc | – y location within glimpse |
| width | – width of the box area |
| height | – height of the box area |
|
extern |
_Glimpse_create_thumbnail – create a thumbox
| xloc | – x location within glimpse thumb area |
| yloc | – y location within glimpse thumb area |
| width | – width of the thumb box |
| height | – height of thumb box |
|
extern |
_Glimpse_draw_thumb – load and draw thumbnail to canvas
| canv | – Pointer to canvas |
| path | – path of the file |
| dst_x | – x coord |
| dst_y | – y coord |
| max_w | – maximum width |
| max_h | – maximum height |
|
extern |
_Glimpse_get_main_glimp – return main glimp area
| void compute_thumb_size | ( | int | src_w, |
| int | src_h, | ||
| int | max_w, | ||
| int | max_h, | ||
| int * | out_w, | ||
| int * | out_h | ||
| ) |
compute_thumb_size – computes the best possible thumbnail size out of given image width and height
| src_w | – source image width |
| src_h | – source image height |
| max_w | – desired maximum width |
| max_h | – desired maximum height |
| out_w | – best possible width |
| out_h | – best possible height |
|
extern |
GlimpseWindowPaint – paint the glimpse window.
| win | – Pointer to window |
|
extern |
thumbnail_box – calculate and prepare the thumbnail using box_filter algorithm
| canvas | – pointer to canvas |
| src | – source image buffer |
| src_w | – source image width |
| src_h | – source image height |
| dst | – destination image buffer |
| dst_w | – destination image width |
| dst_h | – destination image height |