Skip to content

Commit

Permalink
gui: Use more precision dumping pixels.
Browse files Browse the repository at this point in the history
  • Loading branch information
jrfonseca committed Feb 28, 2014
1 parent 9a2e568 commit 8c3fa76
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions gui/imageviewer.cpp
Expand Up @@ -131,10 +131,10 @@ QString createPixelLabel(image::Image *img, int x, int y)
pixel = ((T*)pixelLocation);

pixelLabel += QLatin1String("[");
pixelLabel += QString::fromLatin1("%1").arg(pixel[0]);
pixelLabel += QString::fromLatin1("%1").arg((double)pixel[0], 0, 'g', 9);

for (int channel = 1; channel < img->channels; ++channel) {
pixelLabel += QString::fromLatin1(", %1").arg(pixel[channel]);
pixelLabel += QString::fromLatin1(", %1").arg((double)pixel[channel], 0, 'g', 9);
}
pixelLabel += QLatin1String("]");

Expand Down

0 comments on commit 8c3fa76

Please sign in to comment.