Author Topic: Left and Top anchored UISprite/UILabel offset by one pixel  (Read 9216 times)

cjacobwade

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 1
    • View Profile
Left and Top anchored UISprite/UILabel offset by one pixel
« on: June 13, 2016, 06:17:47 PM »
Working on updating to new version 3.9.7 and mostly going well, except for this and one other issue.



At most screen sizes, all sprites and labels anchored to the left or top side of the screen are offset by one pixel. This still happens even if screen size is even width/height. Still happens in builds. Anyone run into this?

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Left and Top anchored UISprite/UILabel offset by one pixel
« Reply #1 on: June 16, 2016, 03:36:59 AM »
Not one pixel. Half pixel. Search "DX9 half pixel offset". Also you should update to 3.9.9 not 3.9.7.

P.S. And make sure your game window size actually fits whatever you are trying to display. In your example you have 1920x1080 chosen which means your monitor needs to be 2560x1440 or higher just to be able to fit a game view of that size. When things get shrunken down, especially with dimensions not dividable by two cleanly, you will get pixel offsets.
« Last Edit: June 16, 2016, 03:46:03 AM by ArenMook »