Commit eeac116a authored by Marcus D. Hanwell's avatar Marcus D. Hanwell
Browse files

BUG: Also assure the +1 is applied to all textures.

The power of two textures may not get the padding.
parent 40f07f2e
......@@ -995,10 +995,10 @@ void vtkFreeTypeTools::PrepareImageData(vtkImageData *data,
if (this->ScaleToPowerTwo)
{
new_img_dims[0] =
1 << static_cast<int>(ceil(log(static_cast<double>(text_size[0])) /
1 << static_cast<int>(ceil(log(static_cast<double>(text_size[0]+1)) /
log(2.0)));
new_img_dims[1] =
1 << static_cast<int>(ceil(log(static_cast<double>(text_size[1])) /
1 << static_cast<int>(ceil(log(static_cast<double>(text_size[1]+1)) /
log(2.0)));
}
else
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment