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

Start Chalk from a 2D Experience

SOLVED
fbdsilva
Regular Member

Start Chalk from a 2D Experience

Hi Community,

 

I am wondering if would be possible to start Vuforia Chalk App from a Studio 2D Experience like we can do using the Chalk button on 3D Experiences.

I know there is no widget for that but maybe someone can point me to a way to start an app using realwear API from JavaScript.

 

Any ideas are welcome.

 

Thanks in advance,

Felipe Duarte

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Start Chalk from a 2D Experience

Hi @fbdsilva 

we do not have extra chalk widget but calling of chalk in 2d widget but it should work also from Hyperlink widget and also via JavaScript code

So to work this is required:

- chalk is installed on the mobile platform

- I think the first time when you start chalk from Vuforia View  it will request permissions for starting chalk

- this will not work in Preview mode - only on mobile device

Here in the picture  below - there  are shown 2 ways - 1.) hyperlink widget via URL (url=https://admin.vuforiachalk.com/call)

or 2.)  form  button calling js code (it could be any widget supporting UI JS box on click or other actions)

 

 


 

 

2021-03-29_10-56-43.jpg

 

where in US UI  you can use e.g. one of the following js code chalk() or location() - I tested both on IOS  device Ipad and  they are working fine. 

 

 

/////////////////////////////////////////////////// this will not has effect on IOS
$scope.chalk = function ( ) {
  console.log('call https://admin.vuforiachalk.com/call' );
  try{
    
 	window.location.href='https://admin.vuforiachalk.com/call'; 
     twx.app.fn.addSnackbarMessage("window.location.href="+window.location.href,"twLogo");
  }
  catch(e)
  {
    alert('call failed ' + e); 
  }
}
///////////////////////////////////////////////////
//or
///////////////////////////////////////////////////
$scope.location = function () {
 
  try{
    $timeout( () => {var ref = window.location='https://admin.vuforiachalk.com/call' ;
                                        
                 twx.app.fn.addSnackbarMessage("window.location="+ref,"twLogo");},500) 
  }
  catch(e)
  {
    alert('chalk location failed ' + e); 
  }
}

 

 

 

View solution in original post

2 REPLIES 2

Re: Start Chalk from a 2D Experience

Hi @fbdsilva 

we do not have extra chalk widget but calling of chalk in 2d widget but it should work also from Hyperlink widget and also via JavaScript code

So to work this is required:

- chalk is installed on the mobile platform

- I think the first time when you start chalk from Vuforia View  it will request permissions for starting chalk

- this will not work in Preview mode - only on mobile device

Here in the picture  below - there  are shown 2 ways - 1.) hyperlink widget via URL (url=https://admin.vuforiachalk.com/call)

or 2.)  form  button calling js code (it could be any widget supporting UI JS box on click or other actions)

 

 


 

 

2021-03-29_10-56-43.jpg

 

where in US UI  you can use e.g. one of the following js code chalk() or location() - I tested both on IOS  device Ipad and  they are working fine. 

 

 

/////////////////////////////////////////////////// this will not has effect on IOS
$scope.chalk = function ( ) {
  console.log('call https://admin.vuforiachalk.com/call' );
  try{
    
 	window.location.href='https://admin.vuforiachalk.com/call'; 
     twx.app.fn.addSnackbarMessage("window.location.href="+window.location.href,"twLogo");
  }
  catch(e)
  {
    alert('call failed ' + e); 
  }
}
///////////////////////////////////////////////////
//or
///////////////////////////////////////////////////
$scope.location = function () {
 
  try{
    $timeout( () => {var ref = window.location='https://admin.vuforiachalk.com/call' ;
                                        
                 twx.app.fn.addSnackbarMessage("window.location="+ref,"twLogo");},500) 
  }
  catch(e)
  {
    alert('chalk location failed ' + e); 
  }
}

 

 

 

View solution in original post

Re: Start Chalk from a 2D Experience

That´s perfect. It was exactly what I was looking for.

 

Many thanks!

Announcements
Join an
AR Working Group!

Topics available:
AR/VR for Data Optimization AR/VR for Security and Control AR/VR for Inspection