This is one of the script to add sound to the objects..
Using C# :
using UnityEngine;
using System.Collections;
public class AudioPlay : MonoBehaviour {
void Awake()
{
audio.Play();
}
}
It seems that this script is run even when the trackable image is not in the camera.
Did anyone knows how to add the audioplay when the trackable image is set to the camera?
Take a look at the TrackableEventHandler script that comes with the sample applications. Try playing your sound in the the OnTrackingFound method.
- Kim