I need to do a simple pdf with some 3D objects for an oral presentation. I made several views, each one with a camera viewpoint, an object and a display mode.
To avoid the need to manually switch between the different viewpoints with the context menu, I would like the viewpoints to switch automatically with a Timer (each viewpoint staying for a few seconds). And I would like to not have to touch the mouse at all (nor the keyboard), so I would like to have the playback started as soon as the page appears.
I found the javascript command runtime.setView(N,x) to switch to the x’th view among N, but I don’t know where to put it (I don’t want to define a function which will be called when I press a button, since I want everything to be automated). Also, I don’t know how to pause for a few seconds.
Any help ? Thanks !
I believe you’re looking for
setInterval(fn, time)which will call a function periodically at a time interval that you set. I’m not familiar with thesetView()method you mentioned, but here’s some pseudo code that you would put in tags at the end of the document body.The
2000is 2000 milliseconds and is the time interval between executing the function. You can put any number of milliseconds there.The
runtime.setView(N, viewNum)line is something you will have to figure out as I am not familiar with whatever library you’re trying to use there. The operative part of this code is theviewNumvariable which configures which view in rotation should be next.