SCNSceneRendererDelegate

Trait SCNSceneRendererDelegate 

Source
pub unsafe trait SCNSceneRendererDelegate: NSObjectProtocol {
    // Provided methods
    unsafe fn renderer_updateAtTime(
        &self,
        renderer: &ProtocolObject<dyn SCNSceneRenderer>,
        time: NSTimeInterval,
    )
       where Self: Sized + Message { ... }
    unsafe fn renderer_didApplyAnimationsAtTime(
        &self,
        renderer: &ProtocolObject<dyn SCNSceneRenderer>,
        time: NSTimeInterval,
    )
       where Self: Sized + Message { ... }
    unsafe fn renderer_didSimulatePhysicsAtTime(
        &self,
        renderer: &ProtocolObject<dyn SCNSceneRenderer>,
        time: NSTimeInterval,
    )
       where Self: Sized + Message { ... }
    unsafe fn renderer_didApplyConstraintsAtTime(
        &self,
        renderer: &ProtocolObject<dyn SCNSceneRenderer>,
        time: NSTimeInterval,
    )
       where Self: Sized + Message { ... }
    unsafe fn renderer_willRenderScene_atTime(
        &self,
        renderer: &ProtocolObject<dyn SCNSceneRenderer>,
        scene: &SCNScene,
        time: NSTimeInterval,
    )
       where Self: Sized + Message { ... }
    unsafe fn renderer_didRenderScene_atTime(
        &self,
        renderer: &ProtocolObject<dyn SCNSceneRenderer>,
        scene: &SCNScene,
        time: NSTimeInterval,
    )
       where Self: Sized + Message { ... }
}
Available on crate feature SCNSceneRenderer only.
Expand description

Implement this protocol to perform operations at various times during the rendering

See also Apple’s documentation

Provided Methods§

Source

unsafe fn renderer_updateAtTime( &self, renderer: &ProtocolObject<dyn SCNSceneRenderer>, time: NSTimeInterval, )
where Self: Sized + Message,

Implement this to perform per-frame game logic. Called exactly once per frame before any animation and actions are evaluated and any physics are simulated.

Parameter renderer: The renderer that will render the scene.

Parameter time: The time at which to update the scene.

All modifications done within this method don’t go through the transaction model, they are directly applied on the presentation tree.

Source

unsafe fn renderer_didApplyAnimationsAtTime( &self, renderer: &ProtocolObject<dyn SCNSceneRenderer>, time: NSTimeInterval, )
where Self: Sized + Message,

Invoked on the delegate once the scene renderer did apply the animations.

Parameter renderer: The renderer that did render the scene.

Parameter time: The time at which the animations were applied.

All modifications done within this method don’t go through the transaction model, they are directly applied on the presentation tree.

Source

unsafe fn renderer_didSimulatePhysicsAtTime( &self, renderer: &ProtocolObject<dyn SCNSceneRenderer>, time: NSTimeInterval, )
where Self: Sized + Message,

Invoked on the delegate once the scene renderer did simulate the physics.

Parameter renderer: The renderer that did render the scene.

Parameter time: The time at which the physics were simulated.

All modifications done within this method don’t go through the transaction model, they are directly applied on the presentation tree.

Source

unsafe fn renderer_didApplyConstraintsAtTime( &self, renderer: &ProtocolObject<dyn SCNSceneRenderer>, time: NSTimeInterval, )
where Self: Sized + Message,

Invoked on the delegate once the scene renderer did apply the constraints.

Parameter renderer: The renderer that did render the scene.

Parameter time: The time at which the constraints were simulated.

All modifications done within this method don’t go through the transaction model, they are directly applied on the presentation tree.

Source

unsafe fn renderer_willRenderScene_atTime( &self, renderer: &ProtocolObject<dyn SCNSceneRenderer>, scene: &SCNScene, time: NSTimeInterval, )
where Self: Sized + Message,

Available on crate feature SCNScene only.

Invoked on the delegate before the scene renderer renders the scene. At this point the openGL context and the destination framebuffer are bound.

Parameter renderer: The renderer that will render the scene.

Parameter scene: The scene to be rendered.

Parameter time: The time at which the scene is to be rendered.

Starting in 10.10 all modifications done within this method don’t go through the transaction model, they are directly applied on the presentation tree.

Source

unsafe fn renderer_didRenderScene_atTime( &self, renderer: &ProtocolObject<dyn SCNSceneRenderer>, scene: &SCNScene, time: NSTimeInterval, )
where Self: Sized + Message,

Available on crate feature SCNScene only.

Invoked on the delegate once the scene renderer did render the scene.

Parameter renderer: The renderer that did render the scene.

Parameter scene: The rendered scene.

Parameter time: The time at which the scene was rendered.

Starting in 10.10 all modifications done within this method don’t go through the transaction model, they are directly applied on the presentation tree.

Trait Implementations§

Source§

impl ProtocolType for dyn SCNSceneRendererDelegate

Source§

const NAME: &'static str = "SCNSceneRendererDelegate"

The name of the Objective-C protocol that this type represents. Read more
Source§

fn protocol() -> Option<&'static AnyProtocol>

Get a reference to the Objective-C protocol object that this type represents. Read more
Source§

impl<T> ImplementedBy<T> for dyn SCNSceneRendererDelegate

Implementations on Foreign Types§

Source§

impl<T> SCNSceneRendererDelegate for ProtocolObject<T>

Implementors§