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
    • Register
    • Login
    1. Maxon Developers Forum
    2. hey2495
    3. Posts
    H
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 2
    • Posts 2
    • Groups 0

    Posts

    Recent Best Controversial
    • C++ SDK 2026.4 — Supported ordered mouse movement input for keyboard-initiated modal transforms

      Hello Maxon SDK Team,

      I am developing a C++ viewport transformation plugin for Cinema 4D 2026.4, using the Cinema 4D 2026.3 SDK.

      The plugin supports keyboard-initiated modal Move/Rotate/Scale operations (G/R/S), without holding down a mouse button. It needs continuous mouse movement, including when the cursor wraps across viewport boundaries.

      Currently, cursor positions are sampled through GetCursorPos() during viewport cursor callbacks and periodic updates. The plugin uses SetCursorPos() when wrapping is necessary.

      Under rapid mouse movement, especially while holding Shift for precision transforms, we have observed cases where cursor positions appear discontinuous after a warp. A large apparent displacement can then enter the transform calculation.

      We would like to replace this polling-based approach with a properly supported event-based solution, if the Cinema 4D SDK provides one.

      Could you clarify the following?

      Is there a supported way for a C++ plugin to continuously receive ordered mouse movement events during a keyboard-initiated modal operation, without any mouse button held down?

      Can EditorWindow::BfGetInputEvent() be used for this purpose? Does it provide the original mouse event coordinates, modifier state, and reliable ordering relative to cursor repositioning performed through SetCursorPos()?

      Does calling BfGetInputEvent() remove events from the queue that Cinema 4D or other plugins would otherwise process? If so, is there a supported way to preserve or forward events not owned by our plugin?

      If BfGetInputEvent() is not suitable, which API or callback mechanism would Maxon recommend for this type of keyboard-initiated continuous viewport interaction? Are there specific thread, window ownership, or lifecycle restrictions?

      We are specifically looking for the supported SDK input and event ownership contract, rather than a workaround based on motion thresholds, delays, or repeated cursor repositioning.

      Thank you for your guidance.

      posted in Cinema 4D SDK c++ windows 2026
      H
      hey2495
    • C4D 2026.4 — Supported API to release an imported Particle Group Alembic file handle?

      Title: Cinema 4D 2026.4: How to release an Alembic file used by a Particle Group?

      Hi Maxon SDK team,

      I'm developing a Cinema 4D plugin on Windows (Cinema 4D 2026.4). It imports an animated Alembic file as a native Particle Group using c4d.documents.MergeDocument().

      When the archive is no longer needed, I disable the Particle Group cache and clear it:

      • pg.SetParameter(c4d.DescID(c4d.SIMULATION_CACHE_ENABLED), False, c4d.DESCFLAGS_SET_0)
      • doc.ExecutePasses(None, True, True, True, c4d.BUILDFLAGS_NONE)
      • c4d.CallButton(pg, c4d.SIMULATION_DELCACHE)

      The Particle Group then reports zero particles, but Windows still returns [WinError 32] (file in use) when I try to rename the original .abc file.

      I reproduced this with an animated Ogawa Alembic file (22 samples, around 51,700 particles at frame 1) in a fresh test document, without adding Undo entries or changing the source path. The same procedure successfully releases a small, single-sample Alembic file.

      Is there a supported Python or C++ API or workflow that releases the native Particle Group's Alembic file handle while keeping the Cinema 4D document open? Does removing or freeing the imported Particle Group guarantee that the file is released, or is there another required step?

      I can provide the exact test script and a sample Alembic archive if needed.

      posted in Cinema 4D SDK c++ windows 2026 python
      H
      hey2495