Blender
V3.3
|
Go to the source code of this file.
Functions | |
void | BLI_bitmap_draw_2d_line_v2v2i (const int p1[2], const int p2[2], bool(*callback)(int, int, void *), void *user_data) |
void | BLI_bitmap_draw_2d_tri_v2i (const int p1[2], const int p2[2], const int p3[2], void(*callback)(int x, int x_end, int y, void *), void *user_data) |
void | BLI_bitmap_draw_2d_poly_v2i_n (int xmin, int ymin, int xmax, int ymax, const int verts[][2], int verts_len, void(*callback)(int x, int x_end, int y, void *), void *user_data) |
void BLI_bitmap_draw_2d_line_v2v2i | ( | const int | p1[2], |
const int | p2[2], | ||
bool(*)(int, int, void *) | callback, | ||
void * | user_data | ||
) |
Plot a line from p1 to p2 (inclusive).
Definition at line 26 of file bitmap_draw_2d.c.
References callback, error(), user_data, x2, and y1.
Referenced by ED_view3d_depth_read_cached_seg(), and eyedropper_colorband_sample_segment().
void BLI_bitmap_draw_2d_poly_v2i_n | ( | int | xmin, |
int | ymin, | ||
int | xmax, | ||
int | ymax, | ||
const int | verts[][2], | ||
int | verts_len, | ||
void(*)(int x, int x_end, int y, void *) | callback, | ||
void * | user_data | ||
) |
Draws a filled polygon with support for self intersections.
callback | Takes the x, y coords and x-span (x_end is not inclusive), note that x_end will always be greater than x, so we can use: |
Definition at line 315 of file bitmap_draw_2d.c.
References BLI_assert, BLI_qsort_r(), callback, draw_poly_v2i_n__span_y_sort(), max_ii(), MEM_freeN, MEM_mallocN, min_ii(), SWAP, user_data, verts, x, and y.
Referenced by draw_filled_lasso(), DRW_select_buffer_bitmap_from_poly(), sculpt_gesture_init_from_lasso(), and track_mask_gpencil_layer_rasterize().
void BLI_bitmap_draw_2d_tri_v2i | ( | const int | p1[2], |
const int | p2[2], | ||
const int | p3[2], | ||
void(*)(int x, int x_end, int y, void *) | callback, | ||
void * | user_data | ||
) |
Definition at line 203 of file bitmap_draw_2d.c.
References BLI_assert, callback, draw_tri_flat_max(), draw_tri_flat_min(), inv_slope(), ORDER_VARS2, ORDER_VARS3_BY, and user_data.