Here you will find documentation on all the descriptions that Cinema 4D currently has. You can list them Alphabetically, by Type or Plugin . The sample Python and C++ code is automatically generated and in some cases may not be 100% correct. If something doesn't work then please refer to the official Cinema 4D SDK documentation for more information.

Element Information

Sample Code

Example code for the id XSPR_COLOR_MODE in Xpshader

Note that this is not the actual code from the Xpshader file.

This code is just an example to show you how to add a similar control to your own description.

Resource File Code (Xpshader.res)


LONG  XSPR_COLOR_MODE
{
                        
    CYCLE 
    {         XSPR_MODE_PARTICLE; 
        XSPR_MODE_RANDOM; 
        XSPR_MODE_RANGRADIENT; 
        XSPR_MODE_PARAMDEP; 
        XSPR_MODE_USEMODVALUE; 
    }
}
            

Header File Code (Xpshader.h)

#ifndef XPSHADER_H__
#define XPSHADER_H__
enum
{
  XSPR_COLOR_MODE = 1000,  //First ID should start at 1000
    XSPR_MODE_PARTICLE = 1,
    XSPR_MODE_RANDOM = 2,
    XSPR_MODE_RANGRADIENT = 3,
    XSPR_MODE_PARAMDEP = 4,
    XSPR_MODE_USEMODVALUE = 5,
};
#endif	// XPSHADER_H__

String File Code (Xpshader.str)

// C4D-StringResource
// Identifier	Text
STRINGTABLE
{
  XSPR_COLOR_MODE    "Mode";
    XSPR_MODE_PARTICLE    "UseParticleColor";
    XSPR_MODE_RANDOM    "RandomColor";
    XSPR_MODE_RANGRADIENT    "Random(fromGradient)";
    XSPR_MODE_PARAMDEP    "Parameter-Dependent";
    XSPR_MODE_USEMODVALUE    "ModifierSetsValue";
}