<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Animation is not working in Hololense in Vuforia Studio</title>
    <link>https://www.ptcusercommunity.com/t5/Vuforia-Studio/Animation-is-not-working-in-Hololense/m-p/804151#M11040</link>
    <description>&lt;P&gt;&lt;SPAN&gt;I have created 3 animations in 3 different figures in Creo which is not working in Hololense. I have used below java script to call the animation.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;// $scope, $element, $attrs, $injector, $sce, $timeout, $http, $ionicPopup, and $ionicPopover services are available

$scope.setWidgetProp('model-1', 'currentStep', 'stepnr');
$scope.playStep = function (stepnr) {

switch (stepnr) {
case 1:
{
$scope.view.wdg['3DImage-1'].visible=false;
$scope.view.wdg['3DImage-2'].visible=true;
$scope.view.wdg['3DImage-3'].visible=true;
}
break;

case 2:
{
$scope.view.wdg['3DImage-1'].visible=false;
$scope.view.wdg['3DImage-2'].visible=false;
$scope.view.wdg['3DImage-3'].visible=false;
$scope.view.wdg['3DImage-4'].visible=true;
$scope.view.wdg['3DImage-5'].visible=false;
}
break;
case 3:
{
$scope.view.wdg['3DImage-1'].visible=false;
$scope.view.wdg['3DImage-2'].visible=false;
$scope.view.wdg['3DImage-3'].visible=false;
$scope.view.wdg['3DImage-4'].visible=false;
$scope.view.wdg['3DImage-6'].visible=true;
}

}
  
$scope.$applyAsync(() =&amp;gt; {
$scope.setWidgetProp('model-1', 'currentStep', stepnr); });
$timeout(function () {
angular.element(document.getElementById('model-1')).scope().play();
}, 500);
}

$scope.hide = function(){
$scope.view.wdg['3DImage-4']['visible'] = false;
$scope.view.wdg['3DImage-2']['visible'] = true;
$scope.view.wdg['3DImage-3']['visible'] = true;
$scope.view.wdg['3DImage-6']['visible'] = false;
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Each image i have placed "click Js" is below,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;Image-1 - "playStep(1);"

Image-2- "playStep(2); "

Image-3- "playStep(3);"&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Kindly help me to play an animation in Hololense&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/268617"&gt;@tmccombie&lt;/a&gt;&amp;nbsp;&lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/294618"&gt;@sddgtwaw&lt;/a&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Tue, 28 Jun 2022 05:34:57 GMT</pubDate>
    <dc:creator>RK_9880418</dc:creator>
    <dc:date>2022-06-28T05:34:57Z</dc:date>
    <item>
      <title>Animation is not working in Hololense</title>
      <link>https://www.ptcusercommunity.com/t5/Vuforia-Studio/Animation-is-not-working-in-Hololense/m-p/804151#M11040</link>
      <description>&lt;P&gt;&lt;SPAN&gt;I have created 3 animations in 3 different figures in Creo which is not working in Hololense. I have used below java script to call the animation.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;// $scope, $element, $attrs, $injector, $sce, $timeout, $http, $ionicPopup, and $ionicPopover services are available

$scope.setWidgetProp('model-1', 'currentStep', 'stepnr');
$scope.playStep = function (stepnr) {

switch (stepnr) {
case 1:
{
$scope.view.wdg['3DImage-1'].visible=false;
$scope.view.wdg['3DImage-2'].visible=true;
$scope.view.wdg['3DImage-3'].visible=true;
}
break;

case 2:
{
$scope.view.wdg['3DImage-1'].visible=false;
$scope.view.wdg['3DImage-2'].visible=false;
$scope.view.wdg['3DImage-3'].visible=false;
$scope.view.wdg['3DImage-4'].visible=true;
$scope.view.wdg['3DImage-5'].visible=false;
}
break;
case 3:
{
$scope.view.wdg['3DImage-1'].visible=false;
$scope.view.wdg['3DImage-2'].visible=false;
$scope.view.wdg['3DImage-3'].visible=false;
$scope.view.wdg['3DImage-4'].visible=false;
$scope.view.wdg['3DImage-6'].visible=true;
}

}
  
$scope.$applyAsync(() =&amp;gt; {
$scope.setWidgetProp('model-1', 'currentStep', stepnr); });
$timeout(function () {
angular.element(document.getElementById('model-1')).scope().play();
}, 500);
}

$scope.hide = function(){
$scope.view.wdg['3DImage-4']['visible'] = false;
$scope.view.wdg['3DImage-2']['visible'] = true;
$scope.view.wdg['3DImage-3']['visible'] = true;
$scope.view.wdg['3DImage-6']['visible'] = false;
}&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Each image i have placed "click Js" is below,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="javascript"&gt;Image-1 - "playStep(1);"

Image-2- "playStep(2); "

Image-3- "playStep(3);"&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Kindly help me to play an animation in Hololense&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/268617"&gt;@tmccombie&lt;/a&gt;&amp;nbsp;&lt;a href="https://www.ptcusercommunity.com/t5/user/viewprofilepage/user-id/294618"&gt;@sddgtwaw&lt;/a&gt;&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jun 2022 05:34:57 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/Vuforia-Studio/Animation-is-not-working-in-Hololense/m-p/804151#M11040</guid>
      <dc:creator>RK_9880418</dc:creator>
      <dc:date>2022-06-28T05:34:57Z</dc:date>
    </item>
    <item>
      <title>Re: Animation is not working in Hololense</title>
      <link>https://www.ptcusercommunity.com/t5/Vuforia-Studio/Animation-is-not-working-in-Hololense/m-p/804650#M11046</link>
      <description>&lt;P&gt;possibly you can try :&lt;/P&gt;
&lt;LI-CODE lang="javascript"&gt;$scope.setWidgetProp('model-1', 'currentStep', stepnr)
$scope.$applyAsync()
let timeoutValue=300 // if required increase the timeout delay 
//when model more complex to 600 - 1000 milliseconds
$timeout( ()=&amp;gt;{twx.app.fn.triggerWidgetService("model-1", "play");}, 500);&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;so looking on your code it should work but possibly&amp;nbsp; you need more delay and async call after changes if you want to access these changes&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jun 2022 09:15:34 GMT</pubDate>
      <guid>https://www.ptcusercommunity.com/t5/Vuforia-Studio/Animation-is-not-working-in-Hololense/m-p/804650#M11046</guid>
      <dc:creator>RolandRaytchev</dc:creator>
      <dc:date>2022-06-30T09:15:34Z</dc:date>
    </item>
  </channel>
</rss>

