Implementing Polygon2D in Java 2D

后端 未结 3 1843
梦谈多话
梦谈多话 2020-12-28 21:23

I\'m creating a 2D game in Java using the Java2D library for drawing, and I really need a float-precision Polygon object that I can use both to draw game objects and to do c

3条回答
  •  刺人心
    刺人心 (楼主)
    2020-12-28 22:06

    Perhaps have the internals of the polygon at a different scale?

    Multiply by a large number and typecast to int when writing to it, divide by the same large number when reading?

提交回复
热议问题