@jleibs and @Wumpf came up with this design for the blueprint interface, comments meant to be ready as-is:
/// Controls the valid range of data for a 2D view.
///
/// Data outside of this range will not be shown.
/// This acts as a maximum outer clipping rectangle for this view.
/// For controlling panning & zoom of a 2D view, see [`VisualBounds`].
///
/// If no data range is set, it will be determined automatically,
/// based on the bounding-box of the data or other camera information present in the view.
table DataRange (
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Copy"
) {
/// Controls the valid range of data for a 2D view.
///
/// Use this to control the clipping of the view.
// TODO(jleibs): start out with a 2D range, but make this 3D in the future and use it also on the 3d view?
range: rerun.components.DataRange ("attr.rerun.component_required", nullable, order: 1000);
}
/// Controls the visual bounds of a 2D view.
///
/// Everything within these bounds are guaranteed to be visible.
/// Somethings outside of these bounds may also be visible due to letterboxing.
/// For controlling the clipping of a 2D view, see [`DataRange`].
///
/// If no visual bounds are set, they default to the [`DataRange`].
/// Note, that if no [`DataRange`] is set, it will be determined automatically,
/// based on the bounding-box of the data or other camera information present in the view.
table VisualBounds2D (
"attr.rerun.scope": "blueprint",
"attr.rust.derive": "Copy"
) {
/// Controls the visible range of a 2D view.
///
/// Use this to control pan & zoom of the view.
range: rerun.components.VisualBounds2D ("attr.rerun.component_required", nullable, order: 1000);
}
@jleibs and @Wumpf came up with this design for the blueprint interface, comments meant to be ready as-is: