I have a method for drawing strings in 3D that does the following:
- Set a render target
- Draw each character as a quadrangle using a orthographic projection to the render target
- Unset the render target
- Draw the render target texture using a perspective projection and a world transform
My problem is how to deal with strings whose characters length exceeds that of the render target dimensions? For example if I have string "This is a reallllllllllly long string" and the render target can't accommodate it, it will only capture "This is a realllll".
The render target (and its size) could be set each frame but wouldn't that be far too costly?