Skip to content

scenix v0.5.0

Choose a tag to compare

@github-actions github-actions released this 23 May 05:03
· 12 commits to main since this release
0e32e31

scenix v0.5.0

Install

[dependencies]
scenix = "0.5.0"

Highlights

  • New scenix-texture crate with raw CPU texture containers, sampler metadata, deterministic atlas packing, video-frame updates, and RGBA8 mipmap generation.
  • New scenix-camera crate with perspective, orthographic, and cube cameras, WebGPU-depth frustum extraction, screen-to-ray helpers, and orbit/fly controllers.
  • The facade crate now enables the camera and texture features by default alongside scene, mesh, material, and light APIs.
  • Image file decoding and GPU upload remain deferred to the loader and renderer milestones, keeping v0.5.0 dependency-light and renderer-agnostic.

Crates published to crates.io

Crate Version Description
scenix-math 0.5.0 Custom no_std 3D math primitives
scenix-core 0.5.0 Shared IDs, colors, errors, and traits
scenix-input 0.5.0 Platform-agnostic input state types
scenix-scene 0.5.0 GPU-free scene graph and traversal APIs
scenix-camera 0.5.0 GPU-free cameras, frustums, and controllers
scenix-mesh 0.5.0 CPU-side geometry, primitive generation, instancing, and batching
scenix-material 0.5.0 GPU-free material descriptions and pipeline keys
scenix-light 0.5.0 GPU-free lights, shadow configuration, and light probes
scenix-texture 0.5.0 CPU-side texture data, samplers, atlases, and mipmaps
scenix 0.5.0 Facade crate for scenix Textures and Camera APIs

Textures and camera example

use scenix::{PerspectiveCamera, Texture2D, TextureFormat, Vec2, Vec3};

let texture = Texture2D::new(
    1,
    1,
    TextureFormat::Rgba8UnormSrgb,
    vec![255, 255, 255, 255],
)?;

let camera = PerspectiveCamera::new(60.0, 16.0 / 9.0, 0.1, 100.0)
    .position(Vec3::new(0.0, 0.0, 5.0))
    .target(Vec3::ZERO);
let ray = camera.screen_to_ray(Vec2::ZERO);

assert_eq!(texture.base_level_len()?, 4);
assert!(ray.direction.z < 0.0);
# Ok::<(), scenix::ValidationError>(())

Verification

  • cargo test --workspace --all-features
  • cargo test -p scenix-math -p scenix-core -p scenix-input -p scenix-scene -p scenix-camera -p scenix-mesh -p scenix-material -p scenix-light -p scenix-texture --no-default-features
  • cargo clippy --workspace --all-features -- -D warnings
  • cargo fmt --check
  • cargo doc --workspace --all-features --no-deps
  • cargo publish --dry-run for every crate before publish