Debian Codegraph @

thirdparty/msdfgen/core/render-sdf.h

raw symbols SCIP
1
2 #pragma once
3
4 #include "Vector2.hpp"
5 #include "Range.hpp"
6 #include "BitmapRef.hpp"
7
8 namespace msdfgen {
9
10 /// Reconstructs the shape's appearance into output from the distance field sdf.
11 void renderSDF(const BitmapSection<float, 1> &output, const BitmapConstSection<float, 1> &sdf, Range sdfPxRange = 0, float sdThreshold = .5f);
12 void renderSDF(const BitmapSection<float, 3> &output, const BitmapConstSection<float, 1> &sdf, Range sdfPxRange = 0, float sdThreshold = .5f);
13 void renderSDF(const BitmapSection<float, 1> &output, const BitmapConstSection<float, 3> &sdf, Range sdfPxRange = 0, float sdThreshold = .5f);
14 void renderSDF(const BitmapSection<float, 3> &output, const BitmapConstSection<float, 3> &sdf, Range sdfPxRange = 0, float sdThreshold = .5f);
15 void renderSDF(const BitmapSection<float, 1> &output, const BitmapConstSection<float, 4> &sdf, Range sdfPxRange = 0, float sdThreshold = .5f);
16 void renderSDF(const BitmapSection<float, 4> &output, const BitmapConstSection<float, 4> &sdf, Range sdfPxRange = 0, float sdThreshold = .5f);
17
18 /// Snaps the values of the floating-point bitmaps into one of the 256 values representable in a standard 8-bit bitmap.
19 void simulate8bit(const BitmapSection<float, 1> &bitmap);
20 void simulate8bit(const BitmapSection<float, 3> &bitmap);
21 void simulate8bit(const BitmapSection<float, 4> &bitmap);
22
23 }