Hi,
I am currently using bitmap fonts in my Windows Form application and the Tao Framework with wglUseFontBitmapsA but I am having trouble positioning the text properly. I am able to get the text to display on the control and position the text using glrasterpos3f(). I am trying to draw a polar graph in my window and would like to label the angles around the axis. I am able to calculate the positions without any problem for the angles on the right side of the graph but for the angles on the left half of the graph, the text is overlapping onto the graph. I know that this is because the text renders left to right and the raster position is the lower left corner of the first letter. Therefore, I need to compensate for this by subtracting the width of the string from my raster position’s X coordinate. Is there a way to calculate the width of a bitmap string? I know I can accomplish this by getting the difference of the GL_CURRENT_RASTER_POSITION before and after the glCallLists command but by then my text is already rendered. Is there a better method?
Thanks.