geodesic 0.1.0

A Rust library for constructing and sampling 3D geometric scenes.
Documentation
use thiserror::Error;

/// Specific error type for `BvhConfig` validation.
#[expect(clippy::enum_variant_names, reason = "Variant names are descriptive of the error type")]
#[derive(Error, Debug)]
pub enum BvhConfigError {
    #[error("Traverse cost must be positive, got: {cost}")]
    InvalidTraverseCost { cost: String },

    #[error("Intersect cost must be positive, got: {cost}")]
    InvalidIntersectCost { cost: String },

    #[error("SAH buckets must be positive, got: {buckets}")]
    InvalidSahBuckets { buckets: usize },

    #[error("Max shapes per node must be greater than 2, got: {count}")]
    InvalidMaxShapesPerNode { count: usize },

    #[error("Max depth must be positive, got: {depth}")]
    InvalidMaxDepth { depth: usize },
}