Crate msdf_sys

Source

Structs§

_IO_FILE
_IO_codecvt
_IO_marker
_IO_wide_data
msdfgen_Bitmap
msdfgen_BitmapConstRef
msdfgen_BitmapRef
msdfgen_Contour
A single closed contour of a shape.
msdfgen_CubicSegment
A cubic Bezier curve.
msdfgen_EdgeHolder
Container for a single edge of dynamic type.
msdfgen_EdgeSegment
An abstract edge segment.
msdfgen_EdgeSegment__bindgen_vtable
msdfgen_ErrorCorrectionConfig
The configuration of the MSDF error correction pass.
msdfgen_GeneratorConfig
The configuration of the distance field generator algorithm.
msdfgen_LinearSegment
A line segment.
msdfgen_MSDFGeneratorConfig
The configuration of the multi-channel distance field generator algorithm.
msdfgen_Projection
A transformation from shape coordinates to pixel coordinates.
msdfgen_QuadraticSegment
A quadratic Bezier curve.
msdfgen_Scanline
Represents a horizontal scanline intersecting a shape.
msdfgen_Scanline_Intersection
An intersection with the scanline.
msdfgen_Shape
Vector shape representation.
msdfgen_Shape_Bounds
msdfgen_SignedDistance
Represents a signed distance and alignment, which together can be compared to uniquely determine the closest edge segment.
msdfgen_Vector2
A 2-dimensional euclidean vector with double precision. Implementation based on the Vector2 template from Artery Engine. @author Viktor Chlumsky
std_allocator
std_allocator_rebind
std_vector
std_vector__Temporary_value

Constants§

msdfgen_EdgeColor_BLACK
msdfgen_EdgeColor_BLUE
msdfgen_EdgeColor_CYAN
msdfgen_EdgeColor_GREEN
msdfgen_EdgeColor_MAGENTA
msdfgen_EdgeColor_RED
msdfgen_EdgeColor_WHITE
msdfgen_EdgeColor_YELLOW
msdfgen_ErrorCorrectionConfig_DistanceCheckMode_ALWAYS_CHECK_DISTANCE
Computes and compares the exact shape distance for each suspected artifact.
msdfgen_ErrorCorrectionConfig_DistanceCheckMode_CHECK_DISTANCE_AT_EDGE
Only computes exact shape distance at edges. Provides a good balance between speed and precision.
msdfgen_ErrorCorrectionConfig_DistanceCheckMode_DO_NOT_CHECK_DISTANCE
Never computes exact shape distance.
msdfgen_ErrorCorrectionConfig_Mode_DISABLED
Skips error correction pass.
msdfgen_ErrorCorrectionConfig_Mode_EDGE_ONLY
Only corrects artifacts at edges.
msdfgen_ErrorCorrectionConfig_Mode_EDGE_PRIORITY
Corrects artifacts at edges and other discontinuous distances only if it does not affect edges or corners.
msdfgen_ErrorCorrectionConfig_Mode_INDISCRIMINATE
Corrects all discontinuities of the distance field regardless if edges are adversely affected.
msdfgen_FillRule_FILL_NEGATIVE
msdfgen_FillRule_FILL_NONZERO
msdfgen_FillRule_FILL_ODD
msdfgen_FillRule_FILL_POSITIVE

Statics§

msdfgen_ErrorCorrectionConfig_defaultMinDeviationRatio
The default value of minDeviationRatio.
msdfgen_ErrorCorrectionConfig_defaultMinImproveRatio
The default value of minImproveRatio.

Functions§

msdfgen_Contour_addEdge
Adds an edge to the contour.
msdfgen_Contour_addEdge1
Creates a new edge in the contour and returns its reference.
msdfgen_Contour_bound
Adjusts the bounding box to fit the contour.
msdfgen_Contour_boundMiters
Adjusts the bounding box to fit the contour border’s mitered corners.
msdfgen_Contour_reverse
Reverses the sequence of edges on the contour.
msdfgen_Contour_winding
Computes the winding of the contour. Returns 1 if positive, -1 if negative.
msdfgen_CubicSegment_CubicSegment
msdfgen_CubicSegment_bound
msdfgen_CubicSegment_clone
msdfgen_CubicSegment_deconverge
msdfgen_CubicSegment_direction
msdfgen_CubicSegment_directionChange
msdfgen_CubicSegment_moveEndPoint
msdfgen_CubicSegment_moveStartPoint
msdfgen_CubicSegment_point
msdfgen_CubicSegment_reverse
msdfgen_CubicSegment_scanlineIntersections
msdfgen_CubicSegment_signedDistance
msdfgen_CubicSegment_splitInThirds
msdfgen_EdgeHolder_EdgeHolder
msdfgen_EdgeHolder_EdgeHolder1
msdfgen_EdgeHolder_EdgeHolder2
msdfgen_EdgeHolder_EdgeHolder3
msdfgen_EdgeHolder_EdgeHolder4
msdfgen_EdgeHolder_EdgeHolder5
msdfgen_EdgeHolder_EdgeHolder_destructor
msdfgen_EdgeHolder_swap
Swaps the edges held by a and b.
msdfgen_EdgeSegment_distanceToPseudoDistance
Converts a previously retrieved signed distance from origin to pseudo-distance.
msdfgen_LinearSegment_LinearSegment
msdfgen_LinearSegment_bound
msdfgen_LinearSegment_clone
msdfgen_LinearSegment_direction
msdfgen_LinearSegment_directionChange
msdfgen_LinearSegment_length
msdfgen_LinearSegment_moveEndPoint
msdfgen_LinearSegment_moveStartPoint
msdfgen_LinearSegment_point
msdfgen_LinearSegment_reverse
msdfgen_LinearSegment_scanlineIntersections
msdfgen_LinearSegment_signedDistance
msdfgen_LinearSegment_splitInThirds
msdfgen_Projection_Projection
msdfgen_Projection_Projection1
msdfgen_Projection_project
Converts the shape coordinate to pixel coordinate.
msdfgen_Projection_projectVector
Converts the vector to pixel coordinate space.
msdfgen_Projection_projectX
Converts the X-coordinate from shape to pixel coordinate space.
msdfgen_Projection_projectY
Converts the Y-coordinate from shape to pixel coordinate space.
msdfgen_Projection_unproject
Converts the pixel coordinate to shape coordinate.
msdfgen_Projection_unprojectVector
Converts the vector from pixel coordinate space.
msdfgen_Projection_unprojectX
Converts the X-coordinate from pixel to shape coordinate space.
msdfgen_Projection_unprojectY
Converts the Y-coordinate from pixel to shape coordinate space.
msdfgen_QuadraticSegment_QuadraticSegment
msdfgen_QuadraticSegment_bound
msdfgen_QuadraticSegment_clone
msdfgen_QuadraticSegment_convertToCubic
msdfgen_QuadraticSegment_direction
msdfgen_QuadraticSegment_directionChange
msdfgen_QuadraticSegment_length
msdfgen_QuadraticSegment_moveEndPoint
msdfgen_QuadraticSegment_moveStartPoint
msdfgen_QuadraticSegment_point
msdfgen_QuadraticSegment_reverse
msdfgen_QuadraticSegment_scanlineIntersections
msdfgen_QuadraticSegment_signedDistance
msdfgen_QuadraticSegment_splitInThirds
msdfgen_Scanline_Scanline
msdfgen_Scanline_countIntersections
Returns the number of intersections left of x.
msdfgen_Scanline_filled
Decides whether the scanline is filled at x based on fill rule.
msdfgen_Scanline_overlap
msdfgen_Scanline_setIntersections
Populates the intersection list.
msdfgen_Scanline_sumIntersections
Returns the total sign of intersections left of x.
msdfgen_Shape_Shape
msdfgen_Shape_addContour
Adds a contour.
msdfgen_Shape_addContour1
Adds a blank contour and returns its reference.
msdfgen_Shape_bound
Adjusts the bounding box to fit the shape.
msdfgen_Shape_boundMiters
Adjusts the bounding box to fit the shape border’s mitered corners.
msdfgen_Shape_edgeCount
Returns the total number of edge segments
msdfgen_Shape_getBounds
Computes the minimum bounding box that fits the shape, optionally with a (mitered) border.
msdfgen_Shape_normalize
Normalizes the shape geometry for distance field generation.
msdfgen_Shape_orientContours
Assumes its contours are unoriented (even-odd fill rule). Attempts to orient them to conform to the non-zero winding rule.
msdfgen_Shape_scanline
Outputs the scanline that intersects the shape at y.
msdfgen_Shape_validate
Performs basic checks to determine if the object represents a valid shape.
msdfgen_SignedDistance_SignedDistance
msdfgen_SignedDistance_SignedDistance1
msdfgen_Vector2_Vector2
msdfgen_Vector2_Vector21
msdfgen_Vector2_direction
Returns the angle of the vector in radians (atan2).
msdfgen_Vector2_getOrthogonal
Returns a vector with the same length that is orthogonal to this one.
msdfgen_Vector2_getOrthonormal
Returns a vector with unit length that is orthogonal to this one.
msdfgen_Vector2_length
Returns the vector’s length.
msdfgen_Vector2_normalize
Returns the normalized vector - one that has the same direction but unit length.
msdfgen_Vector2_project
Returns a vector projected along this one.
msdfgen_Vector2_reset
Sets the vector to zero.
msdfgen_Vector2_set
Sets individual elements of the vector.
msdfgen_distanceSignCorrection
Fixes the sign of the input signed distance field, so that it matches the shape’s rasterized fill.
msdfgen_distanceSignCorrection1
msdfgen_distanceSignCorrection2
msdfgen_distanceSignCorrection3
msdfgen_distanceSignCorrection4
msdfgen_distanceSignCorrection5
msdfgen_edgeColoringByDistance
The alternative coloring by distance tries to use different colors for edges that are close together. This should theoretically be the best strategy on average. However, since it needs to compute the distance between all pairs of edges, and perform a graph optimization task, it is much slower than the rest.
msdfgen_edgeColoringInkTrap
The alternative “ink trap” coloring strategy is designed for better results with typefaces that use ink traps as a design feature. It guarantees that even if all edges that are shorter than both their neighboring edges are removed, the coloring remains consistent with the established rules.
msdfgen_edgeColoringSimple
Assigns colors to edges of the shape in accordance to the multi-channel distance field technique. May split some edges if necessary. angleThreshold specifies the maximum angle (in radians) to be considered a corner, for example 3 (~172 degrees). Values below 1/2 PI will be treated as the external angle.
msdfgen_estimateSDFError
Estimates the portion of the area that will be filled incorrectly when rendering using the SDF.
msdfgen_estimateSDFError1
msdfgen_estimateSDFError2
msdfgen_estimateSDFError3
msdfgen_estimateSDFError4
msdfgen_estimateSDFError5
msdfgen_generateMSDF
Generates a multi-channel signed distance field. Edge colors must be assigned first! (See edgeColoringSimple)
msdfgen_generateMSDF1
msdfgen_generateMSDF_legacy
msdfgen_generateMTSDF
Generates a multi-channel signed distance field with true distance in the alpha channel. Edge colors must be assigned first.
msdfgen_generateMTSDF1
msdfgen_generateMTSDF_legacy
msdfgen_generatePseudoSDF
Generates a single-channel signed pseudo-distance field.
msdfgen_generatePseudoSDF1
msdfgen_generatePseudoSDF_legacy
msdfgen_generateSDF
Generates a conventional single-channel signed distance field.
msdfgen_generateSDF1
msdfgen_generateSDF_legacy
msdfgen_interpretFillRule
Resolves the number of intersection into a binary fill value based on fill rule.
msdfgen_msdfErrorCorrection
Predicts potential artifacts caused by the interpolation of the MSDF and corrects them by converting nearby texels to single-channel.
msdfgen_msdfErrorCorrection1
msdfgen_msdfErrorCorrection_legacy
The original version of the error correction algorithm.
msdfgen_msdfErrorCorrection_legacy1
msdfgen_msdfFastDistanceErrorCorrection
Applies the simplified error correction to all discontiunous distances (INDISCRIMINATE mode). Does not need shape or translation.
msdfgen_msdfFastDistanceErrorCorrection1
msdfgen_msdfFastEdgeErrorCorrection
Applies the simplified error correction to edges only (EDGE_ONLY mode). Does not need shape or translation.
msdfgen_msdfFastEdgeErrorCorrection1
msdfgen_rasterize
Rasterizes the shape into a monochrome bitmap.
msdfgen_rasterize1
msdfgen_readShapeDescription
Deserializes a text description of a vector shape into output.
msdfgen_readShapeDescription1
msdfgen_renderSDF
Reconstructs the shape’s appearance into output from the distance field sdf.
msdfgen_renderSDF1
msdfgen_renderSDF2
msdfgen_renderSDF3
msdfgen_renderSDF4
msdfgen_renderSDF5
msdfgen_saveBmp
Saves the bitmap as a BMP file.
msdfgen_saveBmp1
msdfgen_saveBmp2
msdfgen_saveBmp3
msdfgen_saveBmp4
msdfgen_saveBmp5
msdfgen_saveTiff
Saves the bitmap as an uncompressed floating-point TIFF file.
msdfgen_saveTiff1
msdfgen_saveTiff2
msdfgen_scanlineSDF
Analytically constructs a scanline at y evaluating fill by linear interpolation of the SDF.
msdfgen_scanlineSDF1
msdfgen_scanlineSDF2
msdfgen_scanlineSDF3
msdfgen_scanlineSDF4
msdfgen_scanlineSDF5
msdfgen_simulate8bit
Snaps the values of the floating-point bitmaps into one of the 256 values representable in a standard 8-bit bitmap.
msdfgen_simulate8bit1
msdfgen_simulate8bit2
msdfgen_writeShapeDescription
Serializes a shape object into a text description.

Type Aliases§

FILE
_IO_lock_t
__off64_t
__off_t
msdfgen_EdgeColor
Edge color specifies which color channels an edge belongs to.
msdfgen_ErrorCorrectionConfig_DistanceCheckMode
Configuration of whether to use an algorithm that computes the exact shape distance at the positions of suspected artifacts. This algorithm can be much slower.
msdfgen_ErrorCorrectionConfig_Mode
Mode of operation.
msdfgen_FillRule
Fill rule dictates how intersection total is interpreted during rasterization.
msdfgen_Point2
A 2-dimensional euclidean vector with double precision. Implementation based on the Vector2 template from Artery Engine. @author Viktor Chlumsky
msdfgen_byte
size_t
std_allocator_const_pointer
std_allocator_const_reference
std_allocator_difference_type
std_allocator_is_always_equal
std_allocator_pointer
std_allocator_propagate_on_container_move_assignment
std_allocator_rebind_other
std_allocator_reference
std_allocator_size_type
std_allocator_value_type
std_vector__Alloc_traits
std_vector__Base
std_vector__Tp_alloc_type
std_vector_allocator_type
std_vector_const_iterator
std_vector_const_pointer
std_vector_const_reference
std_vector_const_reverse_iterator
std_vector_difference_type
std_vector_iterator
std_vector_pointer
std_vector_reference
std_vector_reverse_iterator
std_vector_size_type
std_vector_value_type