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
    • Recent
    • Tags
    • Users
    • Login
    The Maxon SDK Team is currently short staffed due to the winter holidays. No forum support is being provided between 15/12/2025 and 5/1/2026. For details see Maxon SDK 2025 Winter Holidays.

    GetBitmap from channels always NULL

    Scheduled Pinned Locked Moved SDK Help
    4 Posts 0 Posters 494 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 14/02/2003 at 15:06, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   8.012 
      Platform:      Mac OSX  ; 
      Language(s) :     C++  ;

      ---------
      Given a BaseMaterial, I am iterating through the channels on a BaseMaterial and executing this:
      for ( i = 0; i < theChannelIndex; i ++ )
      {
      BaseChannel* baseChannelPtr =  inC4dMaterial->GetChannel( i );
      BaseBitmap* theChannelBitmap = baseChannelPtr->GetBitmap();
      if ( theChannelBitmap != NULL)
      {
      //code here
      }
      }
      I'm going through all the channels and the Real/LONG data is coming fine in the channel, but I am always getting NULL when trying GetBitmap on that channel.
      Anything special I need to do or am not doing?
      Thanks in advance,
      Eric

      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 15/02/2003 at 13:24, xxxxxxxx wrote:

        The bitmap isn't available for shaders. Make sure your material has real texture bitmaps (e.g. mytexture.tif) in its channels and not shaders (Cloud, Gradient). Was this it?

        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 17/02/2003 at 08:34, xxxxxxxx wrote:

          Mikael,
          The channel and material is nothing special.. I just created a new material and go to Diffuse and just load in a texture..ithas a regular ol' bitmap (.jpg) .tga) in it. C4D returns the texture string from:

            
          baseChannelPtr->GetData().GetString( BASECHANNEL_TEXTURE   );  
          

          but when I try:

            
          BaseBitmap* theChannelBitmap = baseChannelPtr->GetBitmap();   
          

          it's always NULL

          U think it only works on certain bitmaps?

          Thanks.

          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 25/02/2003 at 08:01, xxxxxxxx wrote:

            Anyone see any light at the end of the tunnel for this?
            I'm trying a workaround: Newing up a BaseImage and tyring to load in an image into it isntead of getting the empty NULL container..
            I'm trying to do this by getting the filename of the image. However, all i'm seeing is only the real name of the image, not the full path to load the image. is there a way to get the full path name of the image?
            I am in Mac OSX C++
            Thanks again, eric.

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