链接已复制
If you are asking whether Unity will keep tracking the same physical object if it moves or change its tracking to a different physical object ... I would think that Unity woud try to keep tracking the same object, but if that object moves away from the center of the camera's view, becomes too far away or leaves the camera's view totally then the tracking of a particular object is more likely to be lost.
The Unity SDK comes with a program called the Unity Toolkit. You start a new Unity project, then run the Toolkit program whilst your Unity project is open and it imports the RealSense files and plugins into the project so that it will work with the camera.
The toolkit works with the '2016 R2' version of the RealSense SDK. R2 can be downloaded as a 1.8 gb download using the link below.
http://registrationcenter-download.intel.com/akdlm/irc_nas/vcp/9078/intel_rs_sdk_offline_package_10.0.26.0396.exe http://registrationcenter-download.intel.com/akdlm/irc_nas/vcp/9078/intel_rs_sdk_offline_package_10.0.26.0396.exe
You would have to install Unity 2017 first though by downloading it from the Unity website. That is a 1 GB + download too.
When you add the Toolkit to a new Unity project, it should add the camera DLLs that enable the camera to work in Unity. There are not DLLs for specific camera models. The same DLLs are used for all the cameras the Windows RealSense SDK supports in the 2016 R2 SDK (F200, R200, SR300).
The DLLs are called libpxcclr.unity.dll and libpxccpp2c.dll. They are placed by the Toolkit in the 'Plugins' and 'Plugsins_Managed' folders that the Toolkit creates in your project.
You should go to the folder RSUnityToolkit > Actions in your Unity project. Look for a script called TrackingAction in this folder. Hold the left mouse button down on the TrackingAction script and drag it over to your cube with the mouse. When the mouse cursor is over the cube, release the mouse button to drop the TrackingAction script into the cube.
Now when you highlight the cube by left-clicking on it, the TrackingAction script and its menus will be visible in the Inspector panel on the right-hand side of your Unity window.
The 'added to scene' message is nothing to do with object detection. The camera uses a component called the Sense Manager to make camera functions work. If any camera project (not just Unity ones) finds there is not a Sense Manager when the program runs then it creates a Sense Manager component. It is nothing to worry about.
I don't use the Object Tracking part of TrackingAction in my own project (only Hand and Face) so I can only guess at what the problem is.
The first question I would ask is whether you have set TrackingAction for the Object Tracking mode by opening the menu next to the 'Set defaults to' option and selected Object Tracking.
