Skip to main content
17-Peridot
March 5, 2021
Question

Use cases for the TML widget in Vuforia

  • March 5, 2021
  • 3 replies
  • 3214 views

I thought TML widget is only about working with shaders, but according to this post , it can be used for other things, including dynamically creating stuff within experience, 

 

Can someone provide more information / examples on how to use TML widget to dynamically create stuff and / or other use cases?

Help Center is pretty laconic (but intriguing 🙂 ) on this - "The TML Text widget allows you to manually enter TML directly through Vuforia Studio to create a custom widget."

3 replies

16-Pearl
March 5, 2021

Seconded

 

Looking forward to documentation.

12-Amethyst
March 7, 2021

That;s correct.  the tml wiget can be use to inject any tml into the scene.  View is a web browser and Tml is the markup language used to define the 3D AR experience.   Declaring shaders is just one of many uses; probably one of the more advanced, as the shader mechanism itself is generally reserved to cgi professionals who understand how to program GPUs!!   Other tml usecaes e.g. defining trackers, or declaring scene content, these are all possible  Real examples are now being created -

17-Peridot
April 4, 2021

.

17-Peridot
April 4, 2021

Apparently, there is an example of using TML to dynamically highlight parts in the Help Center

Not sure, for how long it has been there, but I haven't seen it.

http://support.ptc.com/help/vuforia/studio/en/#page/Studio_Help_Center%2Fmetadata%2FMetadata_201_Highlight_Parts.html%23

 

 

$scope.hilite = function (items, hilite) {
 items.forEach(function(item) {
 tml3dRenderer.setProperties(item, hilite === true ? { shader: "green", hidden: false, opacity: 0.9, phantom: false, decal: true }
 : { shader: "Default", hidden: false, opacity: 1.0, phantom: false, decal: false });
 }) //foreach end
} //hilite function end

 

16-Pearl
April 6, 2021