Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Game Development
  4. QScreenRayCaster trigger y parameter needs to be "inverted": by design or bug?
Forum Updated to NodeBB v4.3 + New Features

QScreenRayCaster trigger y parameter needs to be "inverted": by design or bug?

Scheduled Pinned Locked Moved Unsolved Game Development
3 Posts 2 Posters 671 Views 1 Watching
  • 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.
  • uaniU Offline
    uaniU Offline
    uani
    wrote on last edited by uani
    #1

    the trigger method of a QScreenRayCaster needs to receive the y-ccordinate of the mouse pointer as subtracted from the viewport height.

    I would have expected a screen ray caster to take a possible OGL different coordinate system origin position into account.

    Thus: bug or by design?

    E 1 Reply Last reply
    0
    • uaniU uani

      the trigger method of a QScreenRayCaster needs to receive the y-ccordinate of the mouse pointer as subtracted from the viewport height.

      I would have expected a screen ray caster to take a possible OGL different coordinate system origin position into account.

      Thus: bug or by design?

      E Offline
      E Offline
      e2002e
      wrote on last edited by
      #2

      @uani screen related protocols does increase Y from the top by convention.

      1 Reply Last reply
      0
      • uaniU Offline
        uaniU Offline
        uani
        wrote on last edited by
        #3

        @e2002e yes, this is how the mouse pointer y coordinate is delivered but when I use it to screenraycast it hits on the opposite vertical side of the entity.

        I subtract the mouse pointer y from the viewport height now to have a QScreenRayCast hit as expected.

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved