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.
ID PREF_UNITS_BASIC
Element Information
Sample Code
Example code for the id PREF_UNITS_BASIC in Prefsunits
Note that this is not the actual code from the Prefsunits file.
This code is just an example to show you how to add a similar control to your own description.
Resource File Code (Prefsunits.res)
LONG PREF_UNITS_BASIC
{
ANIM OFF;
CYCLE
{ PREF_UNITS_BASIC_KM;
PREF_UNITS_BASIC_M;
PREF_UNITS_BASIC_CM;
PREF_UNITS_BASIC_MM;
PREF_UNITS_BASIC_MICRO;
PREF_UNITS_BASIC_NM;
PREF_UNITS_BASIC_MILE;
PREF_UNITS_BASIC_YARD;
PREF_UNITS_BASIC_FOOT;
PREF_UNITS_BASIC_INCH;
}
}
Header File Code (Prefsunits.h)
#ifndef PREFSUNITS_H__
#define PREFSUNITS_H__
enum
{
PREF_UNITS_BASIC = 1000, //First ID should start at 1000
PREF_UNITS_BASIC_KM = 1,
PREF_UNITS_BASIC_M = 2,
PREF_UNITS_BASIC_CM = 3,
PREF_UNITS_BASIC_MM = 4,
PREF_UNITS_BASIC_MICRO = 5,
PREF_UNITS_BASIC_NM = 6,
PREF_UNITS_BASIC_MILE = 7,
PREF_UNITS_BASIC_YARD = 8,
PREF_UNITS_BASIC_FOOT = 9,
PREF_UNITS_BASIC_INCH = 10,
};
#endif // PREFSUNITS_H__
String File Code (Prefsunits.str)
// C4D-StringResource
// Identifier Text
STRINGTABLE
{
PREF_UNITS_BASIC "UnitDisplay";
PREF_UNITS_BASIC_KM "Kilometers";
PREF_UNITS_BASIC_M "Meters";
PREF_UNITS_BASIC_CM "Centimeters";
PREF_UNITS_BASIC_MM "Millimeters";
PREF_UNITS_BASIC_MICRO "Micrometers";
PREF_UNITS_BASIC_NM "Nanometers";
PREF_UNITS_BASIC_MILE "Miles";
PREF_UNITS_BASIC_YARD "Yards";
PREF_UNITS_BASIC_FOOT "Feet";
PREF_UNITS_BASIC_INCH "Inches";
}