Crate drawing_api

Crate drawing_api 

Source

Modules§

approxeq
approxord
Utilities for testing approximate ordering - especially true for floating point types, where NaN’s cannot be ordered.
default
A set of aliases for all types, tagged with the default unknown unit.
dyn_api
num
A one-dimensional length, tagged with its units.

Structs§

Angle
An angle in radians
BoolVector2D
A 2d vector of booleans, useful for component-wise logic operations.
BoolVector3D
A 3d vector of booleans, useful for component-wise logic operations.
Box2D
A 2d axis aligned rectangle represented by its minimum and maximum coordinates.
Box3D
An axis aligned 3D box represented by its minimum and maximum coordinates.
Capabilities
Drawing backend capabilities.
Color
ColorMatrix
ContextVulkanInfo
HomogeneousVector
Homogeneous vector in 3D space.
Length
A one-dimensional distance, with value represented by T and unit of measurement Unit.
Owned
Represents owned T. Useful to pass T to a function when used as Into<Owned<T>>.
ParagraphStyle
PixelUnit
Point2D
A 2d Point tagged with a unit.
Point3D
A 3d Point tagged with a unit.
Range
Rect
A 2d Rectangle optionally tagged with a unit.
RigidTransform3D
A rigid transformation. All lengths are preserved under such a transformation.
Rotation2D
A transform that can represent rotations in 2d, represented as an angle in radians.
Rotation3D
A transform that can represent rotations in 3d, represented as a quaternion.
RoundingRadii
Scale
A scaling factor between two different units of measurement.
SideOffsets2D
A group of 2D side offsets, which correspond to top/right/bottom/left for borders, padding, and margins in CSS, optionally tagged with a unit.
Size2D
A 2d size tagged with a unit.
Size3D
A 3d size tagged with a unit.
TextDecoration
TextDecorationType
TextureDescriptor
Transform2D
A 2d transform represented by a column-major 3 by 3 matrix, compressed down to 3 by 2.
Transform3D
A 3d transform stored as a column-major 4 by 4 matrix.
Translation2D
A 2d transformation from a space to another that can only express translations.
Translation3D
A 3d transformation from a space to another that can only express translations.
UnknownUnit
The default unit.
Vector2D
A 2d Vector tagged with a unit.
Vector3D
A 3d Vector tagged with a unit.

Enums§

BlendMode
BlurStyle
ClipOperation
ColorFilter
ColorFormat
ColorSource
ColorSpace
DrawStyle
FillType
FontStyle
FontWeight
GraphicsApi
ImageFilter
MaskFilter
OptRef
Represents either an owned or borrowed T. Useful to pass T or &'a T to a function when used as Into<OptRef<'a, T>>.
StrokeCap
StrokeJoin
TextAlignment
TextDecorationStyle
TextDirection
TextureSampling
TileMode

Traits§

ColorSourceFragment
ContextGl
ContextVulkan
DisplayList
DisplayListBuilder
DrawingContext
An abstraction over graphics context (like OpenGL or Vulkan context).
Fonts
Reference counted object.
FragmentProgram
Represents a fragment program. Reference counted, thread safe, immutable object.
GlyphInfo
ImageFilterFragment
LineMetrics
Paint
Paragraph
ParagraphBuilder
Path
PathBuilder
Surface
A surface represents a render target. That can be usually a window or a texture.
Texture
Represents an image whose data is resident in GPU memory. Reference counted, thread safe, immutable object.
Trig
Trait for basic trigonometry functions, so they can be used on generic numeric types
VulkanSwapchain

Functions§

box3d
Shorthand for Box3D::new(Point3D::new(x1, y1, z1), Point3D::new(x2, y2, z2)).
bvec2
Shorthand for BoolVector2D { x, y }.
bvec3
Shorthand for BoolVector3D { x, y, z }.
point2
Shorthand for Point2D::new(x, y).
point3
Shorthand for Point3D::new(x, y).
rect
Shorthand for Rect::new(Point2D::new(x, y), Size2D::new(w, h)).
size2
Shorthand for Size2D::new(w, h).
size3
Shorthand for Size3D::new(w, h, d).
vec2
Convenience constructor.
vec3
Convenience constructor.

Type Aliases§

Matrix
PixelPoint
PixelRect
PixelSize