cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you know you can set a signature that will be added to all your posts? Set it here! X

How can i rotate model item continuously is there any Java coding pls provide details

swapnil-3
4-Participant

How can i rotate model item continuously is there any Java coding pls provide details

Hello Sir,

Please can anyone tell me how to rotate a model item using js pls provide any coding

1 REPLY 1
pandersson
13-Aquamarine
(To:swapnil-3)

Hello,

try this code will rotare the model 15 deg

$scope.view.wdg['model-1']['ry'] += 15;


You can create a function that can be called from a JS box. Call it with "rotateRight();" :

$scope.rotateRight = function() {

                                                      $scope.view.wdg['model-1']['ry'] += 15;

                           };

Or you may use interval to rotate it smothly (1 deg / second):

$interval(function() {

  $scope.view.wdg['model-1']['ry'] += 1;

}

          ,1000);

Good luck

Per

Top Tags