Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    Specific mat values

    Scheduled Pinned Locked Moved SDK Help
    2 Posts 0 Posters 162 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H Offline
      Helper
      last edited by

      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);

      1 Reply Last reply Reply Quote 0
      • H Offline
        Helper
        last edited by

        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

        1 Reply Last reply Reply Quote 0
        • First post
          Last post