diff options
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/compositor/operations/COM_VectorBlurOperation.cc | 16 | ||||
-rw-r--r-- | source/blender/render/intern/zbuf.c | 3 |
2 files changed, 16 insertions, 3 deletions
diff --git a/source/blender/compositor/operations/COM_VectorBlurOperation.cc b/source/blender/compositor/operations/COM_VectorBlurOperation.cc index e34b629f457..1d097b37ca5 100644 --- a/source/blender/compositor/operations/COM_VectorBlurOperation.cc +++ b/source/blender/compositor/operations/COM_VectorBlurOperation.cc @@ -180,8 +180,13 @@ void VectorBlurOperation::generate_vector_blur(float *data, inputZ->get_buffer()); } -/* ****************** Spans ******************************* */ -/* span fill in method, is also used to localize data for zbuffering */ +/* -------------------------------------------------------------------- */ +/** \name Spans + * + * Duplicated logic from `zbuf.c`. + * \{ */ + +/** Span fill in method, is also used to localize data for Z-buffering. */ struct ZSpan { /* range for clipping */ int rectx, recty; @@ -327,11 +332,13 @@ static void zbuf_add_to_span(ZSpan *zspan, const float v1[2], const float v2[2]) } for (y = my2; y >= my0; y--, xs0 += dx0) { - /* xs0 is the xcoord! */ + /* xs0 is the X-coordinate! */ span[y] = xs0; } } +/** \} */ + /* ******************** VECBLUR ACCUM BUF ************************* */ struct DrawBufPixel { @@ -339,6 +346,9 @@ struct DrawBufPixel { float alpha; }; +/** + * \note Near duplicate of `zspan_scanconvert` in `zbuf.c` with some minor adjustments. + */ static void zbuf_fill_in_rgba( ZSpan *zspan, DrawBufPixel *col, float *v1, float *v2, float *v3, float *v4) { diff --git a/source/blender/render/intern/zbuf.c b/source/blender/render/intern/zbuf.c index 1812a492ac0..beba10ad82a 100644 --- a/source/blender/render/intern/zbuf.c +++ b/source/blender/render/intern/zbuf.c @@ -19,6 +19,9 @@ /** \file * \ingroup render + * + * \note Some of this logic has been duplicated in `COM_VectorBlurOperation.cc` + * changes here may also apply also apply to that file. */ /*---------------------------------------------------------------------------*/ |