Inertia's picture

half type

Just noticed that Ati's drivers support

16-Bit floating point makes sense for computer graphics, 32-Bit (or higher) precision is quite an overkill for Normals or Texture Coordinates. Do you think it would make sense to add new types to OpenTK like this?

  • half
  • half2
  • half3
  • half4

They don't necessarily have to support any arithmetic operations (use float|double for that), I'm rather thinking about a container that does the pack/unpack and can be easily added to Vertex structs.


Edit: If I'm understanding page 21, section 1.5 correctly, we could use short to store it. SSE5 will support float->half and half->float conversion, so future iterations of Mono could improve conversion speed aswell.


Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
the Fiddler's picture

As long as we treat it as an opaque data type (ala IntPtr), this would be very nice.

I've added a new task at so we can keep track of this.