Skip to main content

DemoOpenWorld3DScene

Struct DemoOpenWorld3DScene 

Source
pub struct DemoOpenWorld3DScene { /* private fields */ }
Expand description

Interactive AAA 3D open-world city scene with PBR shading, BVH ray tracing, model importing, and runtime settings.

Implementations§

Source§

impl DemoOpenWorld3DScene

Construction and runtime-config helpers for DemoOpenWorld3DScene.

Source

pub fn create_lazy_city( quality_signal: Signal<RenderQualityConfig>, time_signal: Signal<f32>, import_signal: Signal<u64>, status_signal: Signal<String>, camera_mode_signal: Signal<u8>, ) -> Self

Creates an empty zero-allocation 3D city placeholder that builds meshes and BVH lazily on first /game3d tick or render.

§Arguments
  • Signal<RenderQualityConfig> - Live quality/RT/resolution configuration signal.
  • Signal<f32> - Live time-of-day sun hour signal.
  • Signal<u64> - Monotonic model import request signal.
  • Signal<String> - Live status feedback signal.
  • Signal<u8> - Active 3D camera mode signal (0=Chase, 1=Hood, 2=Orbit, 3=Aerial).
§Returns
  • Self - Uninitialized lazy 3D scene placeholder.
Source

pub fn create_city( quality_signal: Signal<RenderQualityConfig>, time_signal: Signal<f32>, import_signal: Signal<u64>, status_signal: Signal<String>, camera_mode_signal: Signal<u8>, ) -> Self

Creates the live Vice Boulevard 3D open-world scene bound to reactive runtime settings signals.

§Arguments
  • Signal<RenderQualityConfig> - Live quality/RT/resolution configuration signal.
  • Signal<f32> - Live time-of-day sun hour signal.
  • Signal<u64> - Monotonic model import request signal.
  • Signal<String> - Live status feedback signal.
  • Signal<u8> - Active 3D camera mode signal (0=Chase, 1=Hood, 2=Orbit, 3=Aerial).
§Returns
  • Self - Initialized 3D open-world scene.
Source§

impl DemoOpenWorld3DScene

Source

pub fn get_world(&self) -> &World3D

Source

pub fn get_mut_world(&mut self) -> &mut World3D

Source

pub fn set_world(&mut self, val: World3D) -> &mut Self

Source

pub fn get_renderer(&self) -> &Renderer3D

Source

pub fn get_mut_renderer(&mut self) -> &mut Renderer3D

Source

pub fn set_renderer(&mut self, val: Renderer3D) -> &mut Self

Source

pub fn get_actions(&self) -> &ActionMap

Source

pub fn get_mut_actions(&mut self) -> &mut ActionMap

Source

pub fn set_actions(&mut self, val: ActionMap) -> &mut Self

Source

pub fn get_quality_signal(&self) -> Signal<RenderQualityConfig>

Source

pub fn get_mut_quality_signal(&mut self) -> &mut Signal<RenderQualityConfig>

Source

pub fn set_quality_signal( &mut self, val: Signal<RenderQualityConfig>, ) -> &mut Self

Source

pub fn get_time_signal(&self) -> Signal<f32>

Source

pub fn get_mut_time_signal(&mut self) -> &mut Signal<f32>

Source

pub fn set_time_signal(&mut self, val: Signal<f32>) -> &mut Self

Source

pub fn get_import_signal(&self) -> Signal<u64>

Source

pub fn get_mut_import_signal(&mut self) -> &mut Signal<u64>

Source

pub fn set_import_signal(&mut self, val: Signal<u64>) -> &mut Self

Source

pub fn get_last_import_seq(&self) -> u64

Source

pub fn get_mut_last_import_seq(&mut self) -> &mut u64

Source

pub fn set_last_import_seq(&mut self, val: u64) -> &mut Self

Source

pub fn get_status_signal(&self) -> Signal<String>

Source

pub fn get_mut_status_signal(&mut self) -> &mut Signal<String>

Source

pub fn set_status_signal(&mut self, val: Signal<String>) -> &mut Self

Source

pub fn get_camera_mode_signal(&self) -> Signal<u8>

Source

pub fn get_mut_camera_mode_signal(&mut self) -> &mut Signal<u8>

Source

pub fn set_camera_mode_signal(&mut self, val: Signal<u8>) -> &mut Self

Source

pub fn get_smoothed_fps(&self) -> f32

Source

pub fn get_mut_smoothed_fps(&mut self) -> &mut f32

Source

pub fn set_smoothed_fps(&mut self, val: f32) -> &mut Self

Source

pub fn get_initialized(&self) -> bool

Source

pub fn get_mut_initialized(&mut self) -> &mut bool

Source

pub fn set_initialized(&mut self, val: bool) -> &mut Self

Trait Implementations§

Source§

impl Clone for DemoOpenWorld3DScene

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for DemoOpenWorld3DScene

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl GameScene for DemoOpenWorld3DScene

Deterministic 3D open-world simulation and PBR + BVH ray-traced rendering for DemoOpenWorld3DScene.

Source§

fn fixed_update(&mut self, dt: f32, input: &InputState)

Steps vehicle physics, camera follow, spinning imported models, time-of-day sun, and queued model imports.

§Arguments
  • &Self - Mutable 3D scene.
  • f32 - Fixed simulation timestep in seconds.
  • &InputState - Real-time polled keyboard/pointer state.
Source§

fn update(&mut self, dt: f32, _input: &InputState)

Updates smoothed FPS telemetry for the 3D HUD overlay.

§Arguments
  • &Self - Mutable 3D scene.
  • f32 - Real frame delta time in seconds.
  • &InputState - Current polled input snapshot.
Source§

fn render(&mut self, _alpha: f32, ctx: &mut GameRenderContext<'_>)

Renders the 3D open-world city with live PBR + BVH ray tracing and overlays live telemetry HUD.

§Arguments
  • &Self - Mutable 3D scene.
  • f32 - Interpolation alpha.
  • &mut GameRenderContext<'_> - Immediate-mode viewport draw context.

Auto Trait Implementations§

§

impl Forget for DemoOpenWorld3DScene

§

impl Freeze for DemoOpenWorld3DScene

§

impl Move for DemoOpenWorld3DScene

§

impl RefUnwindSafe for DemoOpenWorld3DScene

§

impl Send for DemoOpenWorld3DScene
where RawVecInner: Send, RawTable<(usize, ())>: Send, RawTable<(GameAction, Vec<KeyCode>)>: Send, RawTable<(GameAction, Vec<PointerButton>)>: Send,

§

impl Sync for DemoOpenWorld3DScene
where RawVecInner: Sync, RawTable<(usize, ())>: Sync, RawTable<(GameAction, Vec<KeyCode>)>: Sync, RawTable<(GameAction, Vec<PointerButton>)>: Sync,

§

impl Unpin for DemoOpenWorld3DScene
where *const u8 is !null: Unpin,

§

impl UnsafeUnpin for DemoOpenWorld3DScene

§

impl UnwindSafe for DemoOpenWorld3DScene

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.