diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-12-08 16:55:11 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-12-08 17:14:10 +0300 |
commit | 61776befc3f88c373e47ccbdf8c75e2ca0f4e987 (patch) | |
tree | 0214b7c5146300d41b7bcbe99f87c92599608e7f /source/blender/editors/gpencil/gpencil_trace.h | |
parent | 8f1997975dc60bc1c18992458603ecd58dfded6d (diff) |
Cleanup: move public doc-strings into headers for 'editors'
Ref T92709
Diffstat (limited to 'source/blender/editors/gpencil/gpencil_trace.h')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_trace.h | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/source/blender/editors/gpencil/gpencil_trace.h b/source/blender/editors/gpencil/gpencil_trace.h index 25d8dac2734..7c62288f65d 100644 --- a/source/blender/editors/gpencil/gpencil_trace.h +++ b/source/blender/editors/gpencil/gpencil_trace.h @@ -59,16 +59,48 @@ struct bGPDframe; #define GPENCIL_TRACE_MODE_SINGLE 0 #define GPENCIL_TRACE_MODE_SEQUENCE 1 +/** + * Print trace bitmap for debugging. + * \param f: Output handle. Use `stderr` for printing + * \param bm: Trace bitmap + */ void ED_gpencil_trace_bitmap_print(FILE *f, const potrace_bitmap_t *bm); +/** + * Return new un-initialized trace bitmap + * \param w: Width in pixels + * \param h: Height in pixels + * \return Trace bitmap + */ potrace_bitmap_t *ED_gpencil_trace_bitmap_new(int32_t w, int32_t h); +/** + * Free a trace bitmap + * \param bm: Trace bitmap + */ void ED_gpencil_trace_bitmap_free(const potrace_bitmap_t *bm); +/** + * Invert the given bitmap (Black to White) + * \param bm: Trace bitmap + */ void ED_gpencil_trace_bitmap_invert(const potrace_bitmap_t *bm); +/** + * Convert image to BW bitmap for tracing + * \param ibuf: ImBuf of the image + * \param bm: Trace bitmap + */ void ED_gpencil_trace_image_to_bitmap(struct ImBuf *ibuf, const potrace_bitmap_t *bm, const float threshold); +/** + * Convert Potrace Bitmap to Grease Pencil strokes + * \param st: Data with traced data + * \param ob: Target grease pencil object + * \param offset: Offset to center + * \param scale: Scale of the output + * \param sample: Sample distance to distribute points + */ void ED_gpencil_trace_data_to_strokes(struct Main *bmain, potrace_state_t *st, struct Object *ob, |