Kudan AR Toolkit
Using the Kudan AR Toolkit
The Toolkit provides several functions.
- Convert images to the marker data format to be used with the framework.
- Convert 3D model file types into a file that is compatible for mobile use.
- Encode video files to be mobile optimised.
- Encode alpha video files.
Select the Marker Converter tab within the Kudan AR Toolkit.
Click on New and select where you would like to place your project file that will contain the marker data.
You can now add images to your project by either using the provided buttons or simply dragging an image in from Finder.
Once you have added your markers simply press the Export to create your .KARMarker file.
The project files are fully compatible with a DVCS such as Git. You can create your own markers for use with KudanAR. To do this, you will need to download the appropriate KudanAR Toolkit for your operating system via the download page of the Kudan website. Within the application, you may create marker sets from image files. These can then be imported to Unity and used with the plugin.
1. If you haven’t already, download the KudanAR Toolkit at www.kudan.eu/download.
2. Run the Toolkit. The window that opens by default will be the one we are going to use, the Marker Converter.
3. Click “New” to create a new Marker set. Save it anywhere.
4. Click “Add Marker” or the small plus + icon at the bottom and find the image file you wish to use as a marker.
5. Be sure to take note of the image width and height, because these are the dimensions that the tracker will look for in Unity.
6. If you want to add multiple markers to the set, you may do so. Kudan supports adding many markers to one set, and having many sets loaded at once. You may have 500 markers in one set, or 500 sets of one marker each.
7. If you make a mistake and add the wrong image, simply click the image to select it and then click the small minus (-) icon to remove it. You can also uncheck the “Export” box so that it isn’t included in the set when it is exported.
8. Once you have as many markers in your set as you want, click export. This will create a dataset of markers as a “KARMarker” file.
9. Within Unity, find the MarkerTracking object in the hierarchy. It is a child of “Kudan Camera”.
10. At the bottom of the “Tracking Method Marker” script, there is a button saying “Generate Marker” or “Add KARMarker asset” depending on your version of the plugin. Click this, search for the KARMarker dataset you created and open it. This will add the set to Unity and create a new Marker asset within the Assets folder.
11. In order to use the markers, they must be the set of trackable data loaded by the camera. This is also found in the “Tracking Method Marker” script. Click “Markers” to drop down the relevant information. In “Element 0”, it will say “DemoMarker (TrackableData)”. This is a default marker, which is the lego picture found within KudanAR -> Samples -> Textures. Either drag and drop the new marker onto Element 0 or click the small circle to search for it.
12. Once the new markers have been loaded, you should be good to go. Run the app and when the camera sees the markers, they should be detected.
To convert your existing 3D model to be compatible with the KudanAR framework, select the 3D Model tab with the Toolkit.
Select your model under the Input section.
Set the save location and press Convert.
The converted file will have the same name as the original, however it will now have the .armodel file extension.
The Video Encode tab will allow you to encode your high bitrate videos into a format that is more optimised for mobile use.
As the engine renders AR at 30fps, it is of no use having a video that is of a higher framerate.
Once you have selected your input video and selected where you wish to save the output, you can also change the framerate of the video.
You will be able to select one of the follow options:
- Same as source
The tool will not allow you to encode your file at a framerate that is higher than that of the source as that would worsen the quality video.
When you have made your choice, simply click the Encode button.
For our encoder to function correctly, please ensure your video dimensions (both height in pixels and width in pixels) is divisible by 2.
The alpha video tab allows you to select chroma keyed PNG files to create a video that will show with an alpha channel using KudanAR.
Simply select your input files and set where you wish for the created movie to be saved.
You can adjust the source and the output framerate if wish in order to better showcase your content.
Once everything is set, press the Process button and wait for your new file to be created.
If the encoder returns a zero byte file, please ensure your video dimensions (both height in pixels and width in pixels) is divisible by 2.
Alternatively you can use Handbrake for re-encoding your video files. You can download our OSX Handbrake presets from here: