|
rcbench
Servo and ESC test bench: panel, IOmcu and shared C
|
gfx internals shared by gfx.c and gfx_text.c. Not part of the public interface (include/gfx.h); nothing outside shared/gfx includes it. More...
Go to the source code of this file.
Macros | |
| #define | GFX_DAMAGE(c, x, y, w, h) |
Report a clipped rectangle written through c to the attached damage record (gfx_damage.h); one load and one branch without one. | |
| #define | GFX_DAMAGE_CLIP(cv, rx, ry, rw, rh) |
GFX_DAMAGE() for a rectangle not yet clipped: intersected with c's clip first, and only while a record is attached. | |
| #define | GFX_INL static inline |
| How the primitives' bodies are declared: plain inline. | |
| #define | TRACE_BOX(c, x, y, w, h) |
| Report a shape's box to the fit check unless held back. | |
| #define | TRACE_HOLD() |
| Hold back the boxes of the spans that fill one shape. | |
| #define | TRACE_RELEASE() |
| End one TRACE_HOLD(). | |
Functions | |
| static bool | canvas_ok (const gfx_canvas_t *c) |
Whether c can be drawn on: it exists, has pixels and a non-empty clip. | |
| GFX_INL void | gfx_pixel_inl (gfx_canvas_t *c, int x, int y, gfx_color_t color) |
| The body of gfx_pixel(): one pixel inside the clip, reported to the damage record. | |
| GFX_INL void | gfx_pixel_put_inl (gfx_canvas_t *c, int x, int y, gfx_color_t color) |
| One pixel inside the clip, not reported to the damage record: for a caller that reported the area it writes in already. | |
| GFX_INL gfx_color_t | gfx_pixel_get_inl (const gfx_canvas_t *c, int x, int y) |
| The body of gfx_pixel_get(). | |
| GFX_INL void | gfx_hline_inl (gfx_canvas_t *c, int x, int y, int w, gfx_color_t color) |
The body of gfx_hline(): a horizontal line through gfx_fill_rect(), drawn leftwards for a negative w. | |
| GFX_INL bool | gfx_clip_intersect_inl (gfx_canvas_t *c, gfx_rect_t r) |
| The body of gfx_clip_intersect(). | |
Variables | |
| int | s_trace_hold |
| The fit check's hold depth: 0 reports, more holds back. | |
gfx internals shared by gfx.c and gfx_text.c. Not part of the public interface (include/gfx.h); nothing outside shared/gfx includes it.
SPDX-License-Identifier: MIT
| #define GFX_DAMAGE | ( | c, | |
| x, | |||
| y, | |||
| w, | |||
| h ) |
Report a clipped rectangle written through c to the attached damage record (gfx_damage.h); one load and one branch without one.
| #define GFX_DAMAGE_CLIP | ( | cv, | |
| rx, | |||
| ry, | |||
| rw, | |||
| rh ) |
GFX_DAMAGE() for a rectangle not yet clipped: intersected with c's clip first, and only while a record is attached.
| #define TRACE_BOX | ( | c, | |
| x, | |||
| y, | |||
| w, | |||
| h ) |
Report a shape's box to the fit check unless held back.
| #define TRACE_HOLD | ( | ) |
Hold back the boxes of the spans that fill one shape.
| #define TRACE_RELEASE | ( | ) |
End one TRACE_HOLD().
|
inlinestatic |
Whether c can be drawn on: it exists, has pixels and a non-empty clip.
| c | the canvas, or NULL |
| GFX_INL bool gfx_clip_intersect_inl | ( | gfx_canvas_t * | c, |
| gfx_rect_t | r ) |
The body of gfx_clip_intersect().
| c | the canvas |
| r | the rectangle the clip narrows to |
| GFX_INL void gfx_hline_inl | ( | gfx_canvas_t * | c, |
| int | x, | ||
| int | y, | ||
| int | w, | ||
| gfx_color_t | color ) |
The body of gfx_hline(): a horizontal line through gfx_fill_rect(), drawn leftwards for a negative w.
| c | the canvas |
| x | the line's first column |
| y | its row |
| w | its length, pixels |
| color | its colour |
| GFX_INL gfx_color_t gfx_pixel_get_inl | ( | const gfx_canvas_t * | c, |
| int | x, | ||
| int | y ) |
The body of gfx_pixel_get().
| c | the canvas |
| x | the pixel's column |
| y | its row |
| GFX_INL void gfx_pixel_inl | ( | gfx_canvas_t * | c, |
| int | x, | ||
| int | y, | ||
| gfx_color_t | color ) |
The body of gfx_pixel(): one pixel inside the clip, reported to the damage record.
| c | the canvas |
| x | the pixel's column |
| y | its row |
| color | its colour |
| GFX_INL void gfx_pixel_put_inl | ( | gfx_canvas_t * | c, |
| int | x, | ||
| int | y, | ||
| gfx_color_t | color ) |
One pixel inside the clip, not reported to the damage record: for a caller that reported the area it writes in already.
| c | the canvas |
| x | the pixel's column |
| y | its row |
| color | its colour |