Fresnel Shader in the Color Channel
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 13/11/2009 at 15:37, xxxxxxxx wrote:
User Information:
Cinema 4D Version: 11
Platform: Windows ;
Language(s) : C++ ;---------
So I have created materials and objects in the plugin that I am working on. I would like to add the fresnel shader to the COLOR channel and change the colors within that fresnel shader. Can someone explain to me how this is done?I have been using :
SetParameter() to set the Color Channel's parameters but the parameter for the color channel that houses the fresnel shader is...
SetParameter(MATERIAL_COLOR_SHADER,?,NULL);
I am not sure what to put for the ? argument.. or if this is even the correct course of action.
Please any help would be greatly appreciated.
Thanks,
~Shawn
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 17/11/2009 at 05:29, xxxxxxxx wrote:
I solved this problem with :
atmosphereMat->InsertShader(fresnelColor, NULL); atmosphereMat->InsertShader(fresnelTrans, NULL); atmosphereMat->GetDataInstance()->SetLink(MATERIAL_COLOR_SHADER, fresnelColor); atmosphereMat->GetDataInstance()->SetLink(MATERIAL_TRANSPARENCY_SHADER, fresnelTrans); fresnelColor->SetParameter(SLA_FRESNEL_GRADIENT,ATMOSPHERIC_COLOR, 0); fresnelTrans->SetParameter(SLA_FRESNEL_GRADIENT,Vector (0,0,0), 1);Now I need to insert color knots into the gradient of the fresnel shader and change their color?
Any idea how to do this?
Thanks,
~Shawn
-
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 17/11/2009 at 05:29, xxxxxxxx wrote:
The Fresnel shader's colors are actually knots of a gradient. They are part of the GradientCustomGui custom GUI and can be accessed through the Gradient custom data type. Please have a look at the GradientShader.cpp SDK example.
cheers,
Matthias -
THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 17/11/2009 at 05:31, xxxxxxxx wrote:
Thanks Matthias, I will look into that
~Shawn