From bf9d97d17b6e9ecc70d8d48f52aca3ade60fc7e4 Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Fri, 21 Aug 2015 02:22:03 +0200 Subject: pose-widget: use unsigned char, sprinkle const --- pose-widget/glwidget.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'pose-widget') diff --git a/pose-widget/glwidget.cpp b/pose-widget/glwidget.cpp index 74f12c27..8bf169df 100755 --- a/pose-widget/glwidget.cpp +++ b/pose-widget/glwidget.cpp @@ -171,9 +171,9 @@ void GLWidget::project_quad_texture() { + uv.x() * (origs[i][2].y() - origs[i][0].y()) + uv.y() * (origs[i][1].y() - origs[i][0].y()); - int r = orig[py * orig_pitch + px * orig_depth + 2]; - int g = orig[py * orig_pitch + px * orig_depth + 1]; - int b = orig[py * orig_pitch + px * orig_depth + 0]; + const unsigned char r = orig[py * orig_pitch + px * orig_depth + 2]; + const unsigned char g = orig[py * orig_pitch + px * orig_depth + 1]; + const unsigned char b = orig[py * orig_pitch + px * orig_depth + 0]; dest[y * dest_pitch + x * dest_depth + 0] = r; dest[y * dest_pitch + x * dest_depth + 1] = g; -- cgit v1.2.3