SceneGraphs.jl

Scene Graphs for abstract (acyclic) representation of 3D Worlds
Author Kirusifix
Popularity
1 Star
Updated Last
3 Years Ago
Started In
April 2021

SceneGraphs.jl

Scene Graphs for abstract (acyclic) representation of 3D Worlds. Designed for 3D engines built upon OpenGL, DirectX, or Vulkan.

SceneGraphs is a relatively complex project under the hood, exposing a simplified API to operate with in your applications. Refer to the documentation for more details.

Example

using SceneGraphs

abstract type AbstractEntity end

struct Entity <: AbstractEntity
    transform::SpriteTransform{Entity, Float64}
end
Entity() = Entity(SpriteTransform())

let scene = Scene3D(), ntt1 = Entity(), ntt2 = Entity(), ntt3 = Entity()
    push!(scene, ntt1)
    
    parent!(ntt3, ntt2)
    parent!(ntt2, ntt1)
    
    translate!(ntt1, 1, 2, 3)
    translate!(ntt2, 2, 3, 4)
    rotate!(ntt2, deg2rad(45))
    scale!(ntt3, 2)
    
    update!(scene)
end

Used By Packages

No packages found.