IF *marker* exists in C3d, then create marker driver

Hi everyone,

I have a set of c3d files in which only part of them have some additionals virtual markers defined, and whenever they are avaialable, I would like to use them instead of the conventional ones but without having to manually open each file to check it.

If I had to do it manually for each subject, I could create specific #define _VLASI or #define _LASI definitions in the subject specific data, and then in the marker protocol something like

#ifdef _VLASI
CreateMarkerDriver LASI (
MarkerName= VLASI,

#ifdef _LASI
CreateMarkerDriver LASI (
MarkerName= LASI,

but this would involve a manual definition for each subject and I want to automatize it to make sure I don't miss any of them.

When loading the model, the data of both markers are imported from the C3d file anyway as:


and I'm struggling to define something like

if "Main.ModelSetup.C3DFileData.Points.Markers.VLASI" exists, then do this,

if it doesn't exist, don't give me an error but proceed as that.

Any suggestion?

Thanks in advance!

Hi Enrico,

I understand your need and it would be nice if this would be possible but unfortunately this is not the possible to do within the same load.

I think the best option would be to to make a small model that would create these defines in a file which the mocap model would then read.

Best regards

Hi Søren,

Thanks for your feedback.
I see, I will then try to automate the creation of these defines in Python and it should also work fine.


This topic was automatically closed 125 days after the last reply. New replies are no longer allowed.