What is New in R21

R21

MAXON API

The MAXON API is a brand new API for Cinema 4D with a different paradigm, with more power and flexibility.

This API is the one used for the Cinema 4D development itself. Meaning that our internal developers use and develop this API.

Previously the CLASSIC API was internally an extra layer in Cinema 4D ecosystem, which become costly to maintain or even sometime too limiting to implement a specific features.
In the long term (when everything will be ported to it) 3rd party developers will have the same amount of customization over Cinema 4D than Maxon developers.
Finally, the MAXON API provides these new features:
  • Clear and consistent naming convention.

  • Modularity concept.

  • Consistent object creation.

  • Error handling; in Python, exceptions are raised when something went wrong.

For more information please read MAXON API Introduction.

C4DPY

c4dpy.exe/app, is now bundled with the Cinema 4D standard installation process.

For more information, see c4dpy.

Extensions Menu

C++ and Python plugins and tools are now located in the “Extensions” menu.

Version and License

With Cinema 4D R21, there are no more different version packages (prime, visualize, studio), so c4d.GeGetSystemInfo() was changed.

These functions were introduced in order to track the enrollment of the current user.
Moreover, Cinema 4D R21 has a completely new license system.

These functions were introduced to retrieve the current license information.
c4d.GeGetVersionType() return value was modified since the package versions changed.

Finally, c4d.GeGetSerialInfo() was modified in order to reflect the new license scheme and should no longer be used by third parties.

See py-licensing-example in Github repository.

Token

It’s now possible to register your own token using c4d.plugins.RegisterToken() or c4d.plugins.RegisterHiddenToken().

See py-render_token example in Github repository.

Fields

It’s now possible to creates masks within a c4d.FieldList with the next methods:

c4d.modules.mograph.FieldOutput and c4d.modules.mograph.FieldOutputBlock now support pivot which correspond to the velocity with the next functions/attributes:

Volume

Cinema 4D R21 support vector volume so maxon.frameworks.volume.VolumeToolsInterface was enhanced with:

Finally, maxon.frameworks.volume.VolumeInterface.GetMinMaxValues() was added to retrieve the range of value stored in the volume.

MSG_GETCUSTOMICON and MSG_GETCUSTOMICON_SETTINGS

With Cinema 4D R21, MSG_GETCUSTOMICON was extend in order to support the addition of icon settings.
c4d.CustomIconSettings and c4d.IconData was introduced to fully support it.

c4d.IconData represents an icon from the C4D icon bitmap.
c4d.CustomIconSettings represents the settings to be filled in the MSG_GETCUSTOMICON to configure the display of the icon.

To not break compatibility of old plugins, the next functions where added:
BitmapButtonCustomGui.SetImage() was modified to support IconData as input type for obj picture.

While MSG_GETCUSTOMICON was modified it still work as before if useDat is set to False (Default value).
If you are willing to use an IconData directly, useDat should be set as True and define the IconData in the dat entry of the dictionary.
For more information see MSG_GETCUSTOMICON

MSG_GETCUSTOMICON_SETTINGS is new and holds a c4d.CustomIconSettings.

Miscellaneous

Fixes

  • Fixed an issue where LoggerInterface.Write() failed.

  • Fixed an issue where BaseArray.__str__() failed if the BaseArray was created from C++.

  • Fixed an issue with the Python Console: Cursor is set to 0 after a clean.

  • Fixed an issue with the Python Console: Dragged UserData get wrong ID when created from copy.

  • Fixed an issue with the Python Console: Dragged object are renamed.

  • Fixed an issue with the Python Script Manager: Python auto indent broken in script manager.

  • Fixed an issue with the Python Script Log and Commander: Commander (Shift+C) commands doesn’t show in the Script Log.

Examples

All 117 examples were completely rewritten, including a new structure, readme, comments.

Besides that around 100 new examples were added as well.

Please checks them on Python Github Repository.

Documentation

R21.022 - Documentation Update 1

R21.026 - Hotfix 1

This hotfix for Cinema 4D R21 did not change any API functionality.

R21.115 - SP1

API

Fixes

  • Fixed a crash with EXR loader when a malformed path was given.

  • Fixed an issue where importing a document with a missing substance asset prompt a MessageBox while it was not allowed to do.

  • Fixed an issue where c4d.gui.BitmapButtonCustomGui doesn’t support border options.

  • Fixed an issue where MCOMMAND_SPLIT didn’t return the resulting spline.

  • Fixed an issue where the value of the created key with CCurve.AddKeyAdaptTangent() was wrong.

  • Fixed a crash when invoking c4d.documents.LoadDocument() using the standard python threading module.

  • Fixed an issue where lPoint argument for SplineData.MakePointBuffer() should be optional but was not.

  • Fixed a crash when hashing a c4d.storage.ByteSeq.

Documentation

R21.115 - SP1 - Documentation Update 1

Remove the double rubric entry of Inheritance in some pages.

The next functions/methods were documented in the Python documentation but didn’t exist.

  • c4d.utils.Pulse() doesn’t exist at all, was removed from doc.

  • TextureTag.GetMln() doesn’t exist at all, was removed from doc.

The next functions/methods were not documented in the Python document but existed so they have been added to the documentation.

R21.207 - SP2

API

This Service pack for Cinema 4D R21 did not change any API functionality.

Fixes

Examples

Documentation

  • Fixed documentation of SculptObject.GetPolygonCopy() where parameters were not described in the documentation.

  • Fixed documentation of BaseBitmap.Scale() where the last parameter was named inprop while it is nprop.

  • Fixed documentation of BaseList2D.GetBit() where the return type was wrong`.

  • Added information about current issue with c4dpy not working correctly with R21 see c4dpy.

API Changelist

See API Changelist R21 page.