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

    Getting point and normal from viewport.

    Scheduled Pinned Locked Moved PYTHON Development
    1 Posts 0 Posters 124 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 07/08/2012 at 08:46, xxxxxxxx wrote:

      Hi!
      I'm looking for a way to get a point on a surface (including the respective normal) by clicking in the view port.
      The only possible solution I've discovered so far is to use the GeRayCollider class, but I'm having a hard time calculating the vector of the ray that would hit the object exactly at the position of the 2D mouse coordinates.
      I'd also have to specify which object I want to check for collision and ideally the method would work on what ever object sits at the position of the mouse click (could possibly be solved by iterating trough all objects of the document).
      Are there any other possibility that I don't know of? Maybe some talented person here on the forum can help me out with a code snippet or some words of wisdom. 🙂

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