Jump to content

Search the Community

Showing results for tags 'perspective'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Welcome to UNIGINE Forums
    • News & Announcements
    • Getting started
  • Development
    • Content Creation
    • World Design
    • Rendering
    • Animation
    • Physics, Navigation and Path Finding
    • UI Systems
    • Sound & Video
    • Editor
    • C++ Programming
    • C# Programming
    • Networking
    • Sim IG (Image Generator)
    • VR Discussions
    • General
  • Improving UNIGINE
    • Documentation
    • Feedback for UNIGINE team
    • Bug Reports
    • Unigine SDK Beta feedback
  • Community
    • Add-on Store (https://store.unigine.com/)
    • Showcase
    • Collaboration
    • Tools, Plugins, Materials & Tutorials
    • General Discussions
  • Legacy
    • UnigineScript

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Found 2 results

  1. [SOLVED] Node 3D to NDC coordinates

    Hi, I need the 2D screen Position of a 3D Node transformation. Can you write me a short code example with unigine matrices form the Player and Node and perspective division to get the NDC coordinates? auto proj = m_player->getProjection(); auto view = m_player->getTransform(); auto obj = instance->second->getNode()->getTransform(); auto projectedPosition = Unigine::Math::Mat4(proj)*view*obj*Unigine::Math::Vec4(0.0, 0.0, 0.0, 1.0); projectedPosition /= glm::abs(projectedPosition.w); x = (projectedPosition.x+1.0f)*0.5f * m_ungineAppHandle->getWidth(); y = (1.f-(projectedPosition.z+1.0f)*0.5f) * m_ungineAppHandle->getHeight(); Thank you in advance, Sebastian
  2. [SOLVED] Orthographic camera

    Hello everyone, I`m having a bit of a problem setting up a proper orthographic camera with C++ API in my projects. It seems that there is no way for me to change a camera projection without creating my own mat4 and passing it as an argument to setProjection to the class camera. Is there any other way around to acomplish this task without going in depth with matrix conversations?
×
×
  • Create New...