Skip to main content
Known Participant
August 3, 2021
Question

buttons and javascript

  • August 3, 2021
  • 1 reply
  • 773 views

Hello all,
I created 3D animation pdf. I need to add buttons like play, pause, reset animation, play next step,play previous step.
I dont have much knowledge in java script. this is the first time im creating some scripts with help of google...

Somehow,successfully i created for Play and Pause animation but i got struck with remaining buttons.

var annot = getAnnots3D(0)[0];
annot.context3D.runtime.play();

If i use 

var annot = getAnnots3D(0)[0];
annot.context3D.reset(); is not working for me.


and i have another query also , when ever i open the 3D pdf ,it started playing automatically.

 

This is my settings, how to stop automatically playing animation , I tried all the option from the above setting file.
Thanks in advance.

This topic has been closed for replies.

1 reply

BarlaeDC
Community Expert
Community Expert
August 3, 2021

Hi,

 

Taking a quick look at the docs there is a play.

annot.context3D.runtime.play();

but there is not a reset, so I would not expect this to work.
annot.context3D.reset(); is not working for me.

 

Are you trying to reset the scene back to its starting position?

 

I do not see something obvious to adjust the 3d object play when open, can you provide a sample file?

Known Participant
August 4, 2021

Hi Barlae,

Please refer the attached pdf.

Im not able to connect the 3D model and buttons through java script. 


Thanks in advance

Known Participant
August 16, 2021

waiting for the answer....