I want to get/set config value with user code.
I think that it will use getConfigValue() and setConfigValue().
However, I don’t know how to specify key.
Can you give me an example about it?
(For example, Depth resolution of RealSense2Module.)
Its not really documented anywhere - much like most of the option settings sadly.
But the values are a set of dotted paths based on the elements in nuitrack.config
So for example to change the ProcessWidth - go into the nuitrack.config - find the element you want … and work out its path:
which is Realsense2Module then Depth then ProcessWidth
that becomes Realsense2Module.Depth.ProcessWidth
Which you then call.
Nuitrack::setConfigValue(“Realsense2Module.Depth.ProcessWidth”, “320” );
A NOTE HOWEVER - you cant make many of these changes while the system is running.
Best option that we have found is to make changes just after nuitrack:init(); runs successfully that way the default values from nuitrack.config are all setup correctly first.
Then you can override any settings you need to change.
Then call DepthSensor::create();
Thanks, It works.
By the way, How is it implemented in what way in NuiTrack?
I think it seems to be just scaling the image, because it enable set to not supported resolutions (e.g. 1920x1080) in RealSense SDK.
To be honest the realsense implementation seems a little be hit and miss at times
- maybe one of the dev’s can give some better input
“ProcessWidth”, “ProcessHeight” is a resolution which raw input stream will be resized into (it will be upscaled/downsampled and cropped to fit aspect ratio if needed).
To change the raw stream, you can add “RawWidth”, “RawHeight”, “FPS” options to the
Realsense2Module.Depth section, for example:
The same applies to
RawWidth=1280, RawHeight=720, FPS=30 are default depth settings for D415. As for D435, default depth settings are RawWidth=848, RawHeight=480, FPS=30.
Please note that these changes may lead to performance issues.
Thanks, I have one question.
There are not included in nuitrack.json contain in sample.
Where is documents about these options?
Find nuitrack.config in installation folder of nuitrack.
There are none frustratingly - Ive asked in the past - hopefully the will document them in more detail at some time soon.
Interesting detail - that actually may explain why the d435 crashes on startup more often the the d415.
848x480 isnt a supported format for some legacy usb3 connectors it seems … if we force those devices back to 640x480 they connect every time.
Good to know
I can’t seem to be able to load data from json array entries using these get/set methods.
For instance, take this portion of the
How can I access the
ConfidenceThreshold value? I tried:
Nuitrack::getConfigValue("RegressionSkeletonization.Filter.CombinationFilter.Confidence.ConfidenceThreshold"); but it returns nothing at all.
Would be useful to have this better documented.
There’s no official support for getting/setting all the values from
nuitrack.config. All available options are listed in Nuitrack Knowledge Base