[package]
name = "curvo"
version = "0.1.85"
authors = ["Masatatsu Nakamura <masatatsu.nakamura@gmail.com"]
edition = "2021"
keywords = ["nurbs", "modeling", "graphics", "3d"]
categories = ["graphics"]
description = "NURBS modeling library"
homepage = "https://github.com/mattatz/curvo"
repository = "https://github.com/mattatz/curvo"
license = "MIT"
readme = "README.md"

[dependencies]
anyhow = "1.0.102"
nalgebra = { version = "0.34", features = ["serde-serialize"] }
num-traits = "0.2.19"
rand = "0.10.0"
rand_distr = { version = "0.6.0", default-features = false, optional = true }
robust = { version = "1.2.0" }
easer = { version = "0.3.0", optional = true }
simba = { version = "0.9.1", default-features = false }
spade = { version = "2.15.1" }
gauss-quad = "0.3.1"
geo = { version = "0.32.0" }
bevy = { version = "0.18.1", optional = true }
bevy_egui = { version = "0.39.1", optional = true }
bevy_infinite_grid = { version = "0.18.0", optional = true }
bevy_normal_material = { version = "0.10.0", optional = true }
bevy_panorbit_camera = { version = "0.34.0", optional = true }
bevy_points = { version = "0.10.0", optional = true }
argmin = "0.11.0"
itertools = "0.14.0"
log = { version = "0.4", optional = true }
serde = { version = "1.0.228", optional = true }
ordered-float = { version = "5.3.0", default-features = false }
hashbrown = "0.16.1"
rayon = { version = "1.11", optional = true }
approx = { version = "0.5", default-features = false, optional = true }

[target.wasm32-unknown-unknown.dependencies]
argmin = { version = "0.11.0", features = ["wasm-bindgen"] }

[dev-dependencies]
approx = { version = "0.5", default-features = false }
serde_json = "1.0.145"

[features]
default = []
# default = ["bevy", "serde", "approx"] # for debugging example
bevy = [
  "dep:easer",
  "dep:rand_distr",
  "dep:bevy",
  "dep:bevy_egui",
  "dep:bevy_infinite_grid",
  "dep:bevy_normal_material",
  "dep:bevy_panorbit_camera",
  "dep:bevy_points",
  "nalgebra/convert-glam030",
]
log = ["dep:log"]
rayon = ["dep:rayon"]
serde = ["dep:serde"]
approx = ["dep:approx"]

[[example]]
name = "interpolate_curve"
path = "examples/interpolate_curve.rs"
required-features = ["bevy"]

[[example]]
name = "periodic_interpolate_curve"
path = "examples/periodic_interpolate_curve.rs"
required-features = ["bevy"]

[[example]]
name = "bezier_curve"
path = "examples/bezier_curve.rs"
required-features = ["bevy"]

[[example]]
name = "circle_curve"
path = "examples/circle_curve.rs"
required-features = ["bevy"]

[[example]]
name = "ellipse_arc_curve"
path = "examples/ellipse_arc_curve.rs"
required-features = ["bevy"]

[[example]]
name = "polyline_curve"
path = "examples/polyline_curve.rs"
required-features = ["bevy"]

[[example]]
name = "split_curve"
path = "examples/split_curve.rs"
required-features = ["bevy"]

[[example]]
name = "loft_surface"
path = "examples/loft_surface.rs"
required-features = ["bevy"]

[[example]]
name = "sweep_surface"
path = "examples/sweep_surface.rs"
required-features = ["bevy"]

[[example]]
name = "revolve_surface"
path = "examples/revolve_surface.rs"
required-features = ["bevy"]

[[example]]
name = "trimmed_surface"
path = "examples/trimmed_surface.rs"
required-features = ["bevy"]

[[example]]
name = "curvature"
path = "examples/curvature.rs"
required-features = ["bevy"]

[[example]]
name = "discontinuity"
path = "examples/discontinuity.rs"
required-features = ["bevy"]

[[example]]
name = "frenet_frame"
path = "examples/frenet_frame.rs"
required-features = ["bevy"]

[[example]]
name = "decompose_curve_into_bezier_segments"
path = "examples/decompose_curve_into_bezier_segments.rs"
required-features = ["bevy"]

[[example]]
name = "decompose_surface_into_bezier_patches"
path = "examples/decompose_surface_into_bezier_patches.rs"
required-features = ["bevy"]

[[example]]
name = "divide_curve_by_arc_length"
path = "examples/divide_curve_by_arc_length.rs"
required-features = ["bevy"]

[[example]]
name = "multiple_degree_curves"
path = "examples/multiple_degree_curves.rs"
required-features = ["bevy"]

[[example]]
name = "intersect_curves"
path = "examples/intersect_curves.rs"
required-features = ["bevy"]

[[example]]
name = "intersect_curve_plane"
path = "examples/intersect_curve_plane.rs"
required-features = ["bevy"]

[[example]]
name = "intersect_surface_curve"
path = "examples/intersect_surface_curve.rs"
required-features = ["bevy"]

[[example]]
name = "intersect_surface_plane"
path = "examples/intersect_surface_plane.rs"
required-features = ["bevy"]

[[example]]
name = "iso_curves"
path = "examples/iso_curves.rs"
required-features = ["bevy"]

[[example]]
name = "boundary_curves"
path = "examples/boundary_curves.rs"
required-features = ["bevy"]

[[example]]
name = "boolean_curves"
path = "examples/boolean_curves.rs"
required-features = ["bevy"]

[[example]]
name = "boolean_curves_animation"
path = "examples/boolean_curves_animation.rs"
required-features = ["bevy"]

[[example]]
name = "closest_point_on_surface"
path = "examples/closest_point_on_surface.rs"
required-features = ["bevy"]

[[example]]
name = "split_surface"
path = "examples/split_surface.rs"
required-features = ["bevy"]

[[example]]
name = "constrained_surface_tessellation"
path = "examples/constrained_surface_tessellation.rs"
required-features = ["bevy"]

[[example]]
name = "constrained_trimmed_surface_tessellation"
path = "examples/constrained_trimmed_surface_tessellation.rs"
required-features = ["bevy"]

[[example]]
name = "offset_curve"
path = "examples/offset_curve.rs"
required-features = ["bevy"]

[[example]]
name = "offset_compound_curve"
path = "examples/offset_compound_curve.rs"
required-features = ["bevy"]

[[example]]
name = "fillet_curve"
path = "examples/fillet_curve.rs"
required-features = ["bevy"]

[[example]]
name = "fillet_compound_curve"
path = "examples/fillet_compound_curve.rs"
required-features = ["bevy"]

[[example]]
name = "customized_tessellation"
path = "examples/customized_tessellation.rs"
required-features = ["bevy"]

[[example]]
name = "morph"
path = "examples/morph.rs"
required-features = ["bevy"]

[[example]]
name = "catmull_rom_curve"
path = "examples/catmull_rom_curve.rs"
required-features = ["bevy"]
