Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware 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
    • Register
    • Login
    1. Home
    2. WickedP
    • Profile
    • Following 0
    • Followers 0
    • Topics 33
    • Posts 91
    • Best 6
    • Controversial 0
    • Groups 0

    WickedP

    @WickedP

    8
    Reputation
    227
    Profile views
    91
    Posts
    0
    Followers
    0
    Following
    Joined Last Online
    Website www.wickedp.com

    WickedP Unfollow Follow

    Best posts made by WickedP

    • RE: Move an object in hierarchy

      Hi Rage,

      you could try CallCommand() with id 1019951 - calling this should delete all selected objects without deleting their children. Might also do what you're after?

      WP.

      posted in Cinema 4D SDK
      WickedPW
      WickedP
    • RE: Scaling of image not working

      Hi gogeta,

      I'm not sure on ScaleBicubic(), but I noticed in your commented line:

      //bitmap->ScaleIt(scaledBitmap, defaultBrightness, true, false);

      That last 'false' flag, try changing that to true. If you're scaling in a non-proportional way that should be true (might fix your non 'squeeze' issue).

      WP.

      posted in Cinema 4D SDK
      WickedPW
      WickedP
    • Link to online docs

      Hi folks,

      Might be nice to have a convenience link (icon) to the online docs up in the header area. Somewhere here where the red circle is:

      0a37cd7c-07d4-4d2b-bca7-9c41cfc35e15-image.png

      Maybe to the high-level docs starting page? Or one to each of the main programming starting pages (C++, Python, Cineware).

      Just a thought.

      WP.

      posted in General Talk
      WickedPW
      WickedP
    • RE: UserArea and EditText

      Do the GeUserArea sections display anything? Or are they just spacers?

      A mock-up picture might help others to visualise.

      How about a 'global' drag and drop function? So, make separate iCustomGui/GeUserAreas for each section. Then just point each of these to the same function held in the parent dialog? That way you only have to write the main drag/catch routine once, in the parent dialog.

      Just a thought.

      WP.

      posted in Cinema 4D SDK
      WickedPW
      WickedP
    • Getting keyboard commands in GeDialog()

      Hi folks,

      I'm wanting to get various CTRL+X key presses in my dialog. I can get keys without the ctrl, and I can get the ctrl without keys, but I can't get any ctrl+key presses. In the dialog's Message() function I've tried variations like:

      case BFM_INPUT:
      {
      BaseContainer KB;
      GetInputState(BFM_INPUT_KEYBOARD,BFM_INPUT_CHANNEL,KB);
      LONG qualifier = KB.GetLong(BFM_INPUT_QUALIFIER,NULL);
      String input = msg.GetString(BFM_INPUT_ASC,"");
      }
      

      but none work. They key is always blank if control is pressed.

      I've seen a couple of older posts that gave some suggestions, but nothing seemed to work.

      Is there a particular way we have to do this? Or does it just not work for our own dialogs?

      WP.

      posted in Cinema 4D SDK c++ sdk
      WickedPW
      WickedP
    • RE: Multi-menu menu, how to

      Thanks @ferdinand,

      Agree. I've avoided using OS-specific calls up until now. But for this one I've had to make an exception. Not an ideal solution, but it seems to work:

      e9057cac-086c-4810-bb9c-c198ecdc2427-image.png

      To get around the lost window focus issue, I'm using the first dialog's Timer() to poll and check if any dialog in the menu has window focus. If none do, e.g., a user has clicked away, the system self-destructs. If a menu selection is made, it sends a Message() back to the calling object with details, and then self-destructs.

      It's all a bit of a hack. But it works. 🤷

      WP.

      Update: I'll mark this thread as solved. If I have any further questions I'll pop back in.

      posted in Cinema 4D SDK
      WickedPW
      WickedP

    Latest posts made by WickedP

    • RE: GUI Bitmap Button Properties

      Hi @merkvilson

      This may not help, I'm not a python coder, but for the padding, it might be worth trying to set the BITMAPBUTTON_NOBORDERDRAW flag. I can't tell from the screen shot if that's happening here, but it might be the button border? See if that helps.

      I'll let others help you with your other queries.

      WP.

      posted in Cinema 4D SDK
      WickedPW
      WickedP
    • RE: Getting font file/directory

      Hi @m_adam,

      No probs. I can work without it.

      I'm more after the font file, I only mentioned the directory thinking it might help.

      I'm using a library to help with draw functions for a user interface, and I'd like to set the font to the same as Cinema's so there's consistency in the look. The library allows you to set a font via a path to the font file.

      Perhaps if the fonts data container could include a Filename/String to the file itself in future? Just a thought.

      Cheers,

      WP.

      posted in Cinema 4D SDK
      WickedPW
      WickedP
    • Getting font file/directory

      Hi Folks,

      Is there a way to get the font file/directory that Cinema4D uses? I can't see how to in the SDK.

      Would like it because I'm leveraging a library that takes a font file as an input, and I'd like to pass it the same as Cinema's in an effort to try and keep the look of the draws as close to C4D as possible, for consistency.

      7956c39a-07d8-402b-913f-d18e3a72d6ff-image.png

      WP.

      posted in Cinema 4D SDK c++
      WickedPW
      WickedP
    • RE: Sub-frame document time

      Is there any way to get around the apparent hard-coded maximum frame rate limit?

      WP.

      posted in Cinema 4D SDK
      WickedPW
      WickedP
    • Sub-frame document time

      Hi folks,

      I have a document in memory and I need to evaluate data to a sub-frame time value. The issue I'm getting is that when I do this:

      BaseTime time = doc->GetTime();
      // adjust time numerator here
      doc->SetTime(time);
      //SetDocumentTime(doc,time);
      doc->ExecutePasses(...);
      

      the document time is floored to the nearest frame, and does not take on the sub-frame value. I can see this, because straight after I execute the document and pull the time again, it's reverted back to the original floored frame. I can however, change to the next full frame.

      I've tried other methods like SetDocumentTime() to no avail.

      Is there a trick I'm missing to this?

      WP.

      posted in Cinema 4D SDK c++ windows
      WickedPW
      WickedP
    • RE: Converting image bit depth

      Thanks @ferdinand,

      Conversion is in memory only. I may output at a later stage, though I do save using BaseBitmap->Save() for those times.

      This episode turned out to be quite more than I bargained for in the end. Had to make some serious project changes. But I do believe I've now solved my image problems (albeit, for now!).

      WP.

      posted in Cinema 4D SDK
      WickedPW
      WickedP
    • Converting image bit depth

      Hi Folks,

      I need to transfer some images into different bit depths (mainly 8 and 32-bits). I see inside Cinema4D there's a few commands for these, such as ID 170657 and ID 170659.

      Is it possible to use these in code, for example, to convert an 8-bit to 32-bit? If so, how?

      WP.

      posted in Cinema 4D SDK c++
      WickedPW
      WickedP
    • RE: BFM_DRAGRECEIVE

      Thanks @m_adam,

      I had to jump through a bunch of hoops with this one, because I put the queue process into a progress dialog so that for large file arrays there's an indicator of progress. Otherwise it just appears to hang and the user won't know why. But this made it tricky when the timer is also used because of the different thread contexts involved with the timer, the progress dialog and everything else on the main thread. But with a bit of care, it seems to work.

      Thanks again,

      WP.

      posted in Cinema 4D SDK
      WickedPW
      WickedP
    • BFM_DRAGRECEIVE

      Hi folks,

      is it possible to get the number of files in a drag operation, before the execution of each one individually?

      case BFM_DRAGRECEIVE:
      {
      	KillEvents();
      
      	if(msg.GetData(BFM_DRAG_FINISHED).GetBool())
      	{
      		/* Custom handle function */
      		Handle_FileDrag(msg);
      	}
      
      	return SetDragDestination(MOUSE_NORMAL);
      }
      

      I'm currently getting multiple executions for a single drop. This isn't too much of an issue for a dozen or so files, but I'm concerned about many hundreds to 10's of thousands. The main issue is that I have to do a redraw for this operation. Is there a way around this?

      WP.

      posted in Cinema 4D SDK sdk c++
      WickedPW
      WickedP
    • RE: ShowBitmap() and image name

      @ferdinand, By the way, just a small forum issue I'm seeing, I noticed my 'Mark as solved' doesn't look right in the menu. Don't know if it's just me or if the css might need some attention?

      1ebc9c69-f3f7-47c0-b13f-bb5a184c9f58-image.png

      Thanks again.

      WP.

      posted in Cinema 4D SDK
      WickedPW
      WickedP