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 ID_MG_SHADER_CHANNELSELECT
Element Information
Sample Code
Example code for the id ID_MG_SHADER_CHANNELSELECT in Oshader_panel
Note that this is not the actual code from the Oshader_panel file.
This code is just an example to show you how to add a similar control to your own description.
Resource File Code (Oshader_panel.res)
LONG ID_MG_SHADER_CHANNELSELECT { FIT_H ; CYCLE { ID_MG_SHADER_CHANNELSELECT_COLOR; ID_MG_SHADER_CHANNELSELECT_LUMINANCE; ID_MG_SHADER_CHANNELSELECT_TRANSPARENCY; ID_MG_SHADER_CHANNELSELECT_ENVIRONMENT; ID_MG_SHADER_CHANNELSELECT_BUMP; ID_MG_SHADER_CHANNELSELECT_ALPHA; ID_MG_SHADER_CHANNELSELECT_SPECULAR; ID_MG_SHADER_CHANNELSELECT_DISPLACEMENT; ID_MG_SHADER_CHANNELSELECT_DIFFUSION; ID_MG_SHADER_CHANNELSELECT_NORMAL; ID_MG_SHADER_CHANNELSELECT_DIRECT; } }
Header File Code (Oshader_panel.h)
#ifndef OSHADER_PANEL_H__ #define OSHADER_PANEL_H__ enum { ID_MG_SHADER_CHANNELSELECT = 1000, //First ID should start at 1000 ID_MG_SHADER_CHANNELSELECT_COLOR = 1, ID_MG_SHADER_CHANNELSELECT_LUMINANCE = 2, ID_MG_SHADER_CHANNELSELECT_TRANSPARENCY = 3, ID_MG_SHADER_CHANNELSELECT_ENVIRONMENT = 4, ID_MG_SHADER_CHANNELSELECT_BUMP = 5, ID_MG_SHADER_CHANNELSELECT_ALPHA = 6, ID_MG_SHADER_CHANNELSELECT_SPECULAR = 7, ID_MG_SHADER_CHANNELSELECT_DISPLACEMENT = 8, ID_MG_SHADER_CHANNELSELECT_DIFFUSION = 9, ID_MG_SHADER_CHANNELSELECT_NORMAL = 10, ID_MG_SHADER_CHANNELSELECT_DIRECT = 11, }; #endif // OSHADER_PANEL_H__
String File Code (Oshader_panel.str)
// C4D-StringResource // Identifier Text STRINGTABLE { ID_MG_SHADER_CHANNELSELECT "Channel"; ID_MG_SHADER_CHANNELSELECT_COLOR "Color"; ID_MG_SHADER_CHANNELSELECT_LUMINANCE "Luminance"; ID_MG_SHADER_CHANNELSELECT_TRANSPARENCY "Transparency"; ID_MG_SHADER_CHANNELSELECT_ENVIRONMENT "Environment"; ID_MG_SHADER_CHANNELSELECT_BUMP "Bump"; ID_MG_SHADER_CHANNELSELECT_ALPHA "Alpha"; ID_MG_SHADER_CHANNELSELECT_SPECULAR "Specular"; ID_MG_SHADER_CHANNELSELECT_DISPLACEMENT "Displacement"; ID_MG_SHADER_CHANNELSELECT_DIFFUSION "Diffusion"; ID_MG_SHADER_CHANNELSELECT_NORMAL "Normal"; ID_MG_SHADER_CHANNELSELECT_DIRECT "CustomShader"; }