android support
git-svn-id: svn://db.shs.com.ru/libs@257 a8b55f48-bf90-11e4-a774-851b48703e85
This commit is contained in:
@@ -227,7 +227,11 @@ void Graphic::canvasPaintEvent(QPaintEvent * ) {
|
||||
//phei = hei;
|
||||
QPainter p;
|
||||
if (isOGL) {
|
||||
#ifdef ANDROID
|
||||
p.fillRect(canvas->rect(), Qt::black);
|
||||
#else
|
||||
glClearColor(0.f, 0.f, 0.f, 0.f);
|
||||
#endif
|
||||
p.begin(canvas);
|
||||
} else p.begin(buffer);
|
||||
p.fillRect(canvas->rect(), back_color);
|
||||
@@ -242,8 +246,10 @@ void Graphic::canvasPaintEvent(QPaintEvent * ) {
|
||||
}
|
||||
p.setRenderHint(QPainter::Antialiasing, aalias);
|
||||
if (isOGL) {
|
||||
#ifndef ANDROID
|
||||
if (aalias) glEnable(GL_MULTISAMPLE);
|
||||
else glDisable(GL_MULTISAMPLE);
|
||||
#endif
|
||||
}
|
||||
//p.setRenderHint(QPainter::HighQualityAntialiasing, aalias);
|
||||
if (!aalias) p.translate(-0.5, -0.5);
|
||||
|
||||
Reference in New Issue
Block a user