Specific mat values

THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

On 03/12/2004 at 03:58, xxxxxxxx wrote:

User Information:
Cinema 4D Version:   7.3 
Platform:   Windows  ;   
Language(s) :   C.O.F.F.E.E  ;

---------
I know how to set a bump strength value as seen below but can't figure out how to get what the exact value is if it already exists. Basically I want to get the specific value and adjust the bump strength based upon that value. Please forgive me if this is a stupid question I'm certainly not the sharpest tool in the shed.

if ( (mat->GetChannelState(CHANNEL_BUMP)) && (bumpalter) ) {
a = mat->GetChannel(CHANNEL_BUMP);
b = a->GetContainer();
matname = b->GetData(CH_TEXTURE);
if (matname != "") {          
b = mat->GetMainData();
b->SetData(BUMP_STRENGTH, .5);
mat->SetMainData(b);

THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

On 05/12/2004 at 04:01, xxxxxxxx wrote:

hi,

not sure why you don´t know but actually all you need to do to get the value is

var strength = b->GetData(BUMP_STRENGTH);

HTH