Skip to main content
1-Visitor
Feb 21, 2021 3:59 PM UTC
Solved

Get scanned ThinkMark ID Value

Hi,

 

How can I get the value of a scanned ThingMark in vuforia, I want to get the value of a scanned value - meaning the id on a printed thingmark not the id on studio.

 

I have been trying to use "setupTrackingEventsCommand" function but I did not succeed.

 

 

thanks in  advance.

sebbenAnswer
14-Alexandrite
Feb 23, 2021 6:15 PM UTC

Hi,

 

maybe you can do it like this:

$scope.$on("trackingacquired",function (evt, data){
 $scope.view.wdg['label-1']['text'] = data;
 }
);

 

9 replies

14-Alexandrite
Feb 22, 2021 6:51 AM UTC

Hi,

 

you can get the ThingMark Id with:

 

$scope.view.wdg["thingMark-1"].markerId;

 

Just use this in a function and call it from the Tracking Acquired eventof your ThingMark.

 

Note that in preview it won't show anything unless you enter your ThingMark Id in the ThingMark property of your ThingMark. On a device you don't have to this.

Translate
MaF1-VisitorAuthor
1-Visitor
Feb 22, 2021 7:18 AM UTC

Thank you for reply.

I tried the solution but it does not yield the desired results:

 

What I want is to get the value of a scanned thingmark- meaning the id of a printed thingmark not the id on studio.

 

When I scan I want the value of a printed thingmark's ID if on paper I have ID 123:1 and I scan I want to get that value.

Hope the above makes sense.

On a barcode scanner we use me.scannedValue which give the currently scanned I want something similar for a thingmark.

 

Thank you.

 

Translate
sebben14-AlexandriteAnswer
14-Alexandrite
Feb 23, 2021 6:15 PM UTC

Hi,

 

maybe you can do it like this:

$scope.$on("trackingacquired",function (evt, data){
 $scope.view.wdg['label-1']['text'] = data;
 }
);

 

Translate