Crate re_renderer

Source
Expand description

Rerun’s renderer.

A wgpu based renderer wgpu for all your visualization needs. Used in re_runner to display the contents of any view contents other than pure UI.

§Feature flags

  • import-obj (enabled by default) — Support importing .obj files
  • import-gltf (enabled by default) — Support importing .gltf and .glb files
  • import-stl (enabled by default) — Support importing binary & ascii .stl files
  • serde — Enable (de)serialization using serde.

Re-exports§

pub use importer::CpuMeshInstance;
pub use importer::CpuModel;
pub use importer::CpuModelMeshKey;
pub use texture_info::Texture2DBufferInfo;
pub use view_builder::ViewBuilder;

Modules§

device_caps
external
importer
mesh
renderer
resource_managers
Resource managers are concerned with mapping (typically) higher level user data to their Gpu representation.
texture_info
video
view_builder

Macros§

include_file
A macro to read the contents of a file on disk, and resolve #import clauses as required.
include_shader_module
Create a shader module using the include_file! macro and set the path name as debug string.

Structs§

Color32
This format is used for space-efficient color representation (32 bits).
DebugLabel
Label for resources. Optimized out in release builds.
FileResolver
The FileResolver handles both resolving import clauses and doing the actual string interpolation.
FileServer
A noop implementation of a FileServer.
Hsva
Hue, saturation, value, alpha. All in the range [0, 1]. No premultiplied alpha.
ImportClause
A pre-parsed import clause, as in #import <something>.
LineDrawableBuilder
Builder for a vector of line strips, making it easy to create crate::renderer::LineDrawData.
LineStripBuilder
OutlineConfig
OutlineMaskPreference
What outline (if any) should be drawn.
PickingLayerId
Combination of PickingLayerObjectId and PickingLayerInstanceId.
PickingLayerInstanceId
The second 64bit of the picking layer.
PickingLayerObjectId
The first 64bit of the picking layer.
PickingLayerProcessor
Manages the rendering of the picking layer pass, its render targets & readback buffer.
PointCloudBatchBuilder
PointCloudBuilder
Builder for point clouds, making it easy to create crate::renderer::PointCloudDrawData.
QueueableDrawData
Type erased draw data that can be submitted directly to the view builder.
RectF32
A 2D rectangle with float coordinates.
RectInt
A 2D rectangle with integer coordinates.
RectTransform
Defines a transformation from a rectangular region of interest into a rectangular target region.
RenderConfig
Configures global properties of the renderer.
RenderContext
Any resource involving wgpu rendering which can be re-used across different scenes. I.e. render pipelines, resource pools, etc.
Rgba
0-1 linear space RGBA color with premultiplied alpha.
Rgba32Unmul
RGBA color in sRGB gamma space, with separate/unmultiplied linear alpha.
ScreenshotProcessor
SearchPath
Specifies where to look for imports when both absolute and relative resolution fail.
Size
A size of something in either scene units or ui points.
WgpuResourcePoolStatistics

Enums§

Colormap
CpuWriteGpuReadError
MsaaMode
Controls MSAA (Multi-Sampling Anti-Aliasing)
RenderContextError

Traits§

FileSystem
A very limited filesystem, just enough for our internal needs.

Functions§

adapter_info_summary
A human-readable summary about an adapter
colormap_cyan_to_yellow_srgb
Returns a gamma-space sRGB in 0-255 range.
colormap_inferno_srgb
Returns sRGB polynomial approximation from Inferno color map, assuming t is normalized.
colormap_magma_srgb
Returns sRGB polynomial approximation from Magma color map, assuming t is normalized.
colormap_plasma_srgb
Returns sRGB polynomial approximation from Plasma color map, assuming t is normalized.
colormap_srgb
colormap_turbo_srgb
Returns sRGB polynomial approximation from Turbo color map, assuming t is normalized.
colormap_viridis_srgb
Returns sRGB polynomial approximation from Viridis color map, assuming t is normalized.
get_filesystem
Returns the recommended filesystem handle for the current platform.
grayscale_srgb
Returns an sRGB gray value, assuming t is normalized.
new_recommended_file_resolver
Returns the recommended FileResolver for the current platform/target.
pad_rgb_to_rgba
Pad RGB to RGBA with the given alpha.

Type Aliases§

DepthOffset
Depth offset used to resolve z-fighting between 2D primitives.
GpuReadbackIdentifier
Identifier used to identify a buffer upon retrieval of the data.
RecommendedFileResolver
The recommended FileResolver type for the current platform/target.