but then straight after you get the copy from the buffer and also called it "scene" so you're replacing it anyway.
Original Message:
Sent: 08-31-2023 12:45
From: Nick Kubinski
Subject: Animate 3D Object Live In Framebuffer
Ah ok, because we're already calling up the SceneDirector attached to that scene.
------------------------------
[Nick] [Kubinski]
[Studio Production Specialist]
[Sysmex America Inc.]
[Vernon Hills] [USA]
Original Message:
Sent: 08-30-2023 14:44
From: Simon Redmile
Subject: Animate 3D Object Live In Framebuffer
you can lose this line.
engine.GetSceneByName("XN-550", scene)
------------------------------
Simon Redmile
Senior Graphic Programmer & Designer
Ross Video
Bristol United Kingdom
Original Message:
Sent: 08-30-2023 14:26
From: Nick Kubinski
Subject: Animate 3D Object Live In Framebuffer
That works perfectly Simon. Thank you very much for all the help!
dim scene as xpScenedim sd as xpSceneDirectordim channel as xpOutputFrameBufferengine.GetOutputFrameBuffer(0, channel)engine.GetSceneByName("XN-550", scene)channel.GetSceneOnLayer(0, scene)scene.GetSceneDirectorByName("550 Spin", sd)sd.PlayRange(0,200)
------------------------------
[Nick] [Kubinski]
[Studio Production Specialist]
[Sysmex America Inc.]
[Vernon Hills] [USA]
Original Message:
Sent: 08-30-2023 11:46
From: Simon Redmile
Subject: Animate 3D Object Live In Framebuffer
yeah what your current script is doing is taking the original template online each time.
What you can do instead is this, which would get a scene on layer 0 from your first framebuffer (0). This assume there is a scene online FB 1, layer 0.
dim channel as xpOutputFrameBuffer
dim scene as xpScene
Engine.GetOutputFrameBuffer(0, channel)
channel.GetSceneOnLayer(0, scene)
------------------------------
Simon Redmile
Senior Graphic Programmer & Designer
Ross Video
Bristol United Kingdom
Original Message:
Sent: 08-30-2023 11:41
From: Nick Kubinski
Subject: Animate 3D Object Live In Framebuffer
That would definitely be of interest. I tried removing "scene.SetOnline(0)" from any subsequent scripts, but then I don't see the animation play out in the Framebuffer.
------------------------------
[Nick] [Kubinski]
[Studio Production Specialist]
[Sysmex America Inc.]
[Vernon Hills] [USA]
Original Message:
Sent: 08-30-2023 04:20
From: Simon Redmile
Subject: Animate 3D Object Live In Framebuffer
looks good, if the scene is already online you wouldn't need to set it online, you can pull it from the frame buffer instead. Let me know if that would be of interest.
------------------------------
Simon Redmile
Senior Graphic Programmer & Designer
Ross Video
Bristol United Kingdom
Original Message:
Sent: 08-29-2023 15:56
From: Nick Kubinski
Subject: Animate 3D Object Live In Framebuffer
Thanks Simon! Ok, so just using Playrange to trigger the various sections of the animation, here's what I've got.
dim scene as xpScenedim sd as xpSceneDirectorengine.GetSceneByName("Scene1", scene)scene.GetSceneDirectorByName("Cube Spin", sd)sd.PlayRange(0,50)scene.SetOnline(0)
Also, I didn't know that PlayRange works in reverse too if you switch up the 2 values. I was able to delete the redundant "sd.Playdirection = 0" bit of code.
------------------------------
[Nick] [Kubinski]
[Studio Production Specialist]
[Sysmex America Inc.]
[Vernon Hills] [USA]
Original Message:
Sent: 08-29-2023 05:02
From: Simon Redmile
Subject: Animate 3D Object Live In Framebuffer
personally I wouldn't use pause and resumes and things with scripting.
I would create triggers for each part of the animation and just use playrange and trigger as required.
------------------------------
Simon Redmile
Senior Graphic Programmer & Designer
Ross Video
Bristol United Kingdom
Original Message:
Sent: 08-28-2023 15:45
From: Nick Kubinski
Subject: Animate 3D Object Live In Framebuffer
Thanks for the help Simon!
I was able to get some additional control over the animation via the PlayDirection and Track.Enabled properties. I'm a little stuck with the PlayState and Continue properties though. I'm trying to use the same keyboard shortcut/GPI to continue the animation after it has hit the Pause event in the Scene Director. I know there's a Resume Channel function, but I won't be able to pair that with the reverse play direction.
dim scene as xpScenedim sd as xpSceneDirectordim track as xpSceneDirectorTrackdim playState as PlayStateengine.GetSceneByName("Scene1", scene)scene.GetSceneDirectorByName("Front to Front", sd)sd.GetTrackByName("90 Rotation", track)scene.SetOnline(0)sd.PlayDirection = 0track.Enabled = 1sd.PlayState()sd.Continue
------------------------------
[Nick] [Kubinski]
[Studio Production Specialist]
[Sysmex America Inc.]
[Vernon Hills] [USA]
Original Message:
Sent: 08-23-2023 17:14
From: Simon Redmile
Subject: Animate 3D Object Live In Framebuffer
I would have a single scene director with the entire animation and then from scripts trigger the parts of the scene director you wish to trigger.
For example.
Dim sd as xpSceneDirector
Scene.GetSceneDirectorByName("Spin", sd)
sd.playrange(30, 90)
which would play frames between 30 and 90.
let me know if you need logic beyond that and I can help.
------------------------------
Simon Redmile
Senior Graphic Programmer & Designer
Ross Video
Bristol United Kingdom
Original Message:
Sent: 08-23-2023 16:35
From: Nick Kubinski
Subject: Animate 3D Object Live In Framebuffer
Hello!
I was wondering if anyone knew how to control a scene's Animation Controller from the Sequencer side of Xpression. I'd like to take a 3D model online to Framebuffer 1, then using scripts or Visual Logic, trigger certain parts of the animation such as rotating 90 degrees on the x-axis. I was able to get the below VL built, but unfortunately the model doesn't animate between the 6 rotations, it just jumps to them.
I then made an Animation Controller to spin the model around, but I can't figure out how to affect "AnimController1" with a script on the Sequencer side of things.
------------------------------
[Nick] [Kubinski]
[Studio Production Specialist]
[Sysmex America Inc.]
[Vernon Hills] [USA]
------------------------------