mirror of
https://github.com/overte-org/overte.git
synced 2025-08-08 14:37:46 +02:00
Rename OpenGLInfo to OpenGLVersionChecker
This commit is contained in:
parent
af3d842e60
commit
b7134c75c3
3 changed files with 13 additions and 13 deletions
|
@ -1,5 +1,5 @@
|
||||||
//
|
//
|
||||||
// OpenGLInfo.cpp
|
// OpenGLVersionChecker.cpp
|
||||||
// interface/src
|
// interface/src
|
||||||
//
|
//
|
||||||
// Created by David Rowe on 28 Jan 2016.
|
// Created by David Rowe on 28 Jan 2016.
|
||||||
|
@ -9,19 +9,19 @@
|
||||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||||
//
|
//
|
||||||
|
|
||||||
#include "OpenGLInfo.h"
|
#include "OpenGLVersionChecker.h"
|
||||||
|
|
||||||
#include <QMessageBox>
|
#include <QMessageBox>
|
||||||
#include <QRegularExpression>
|
#include <QRegularExpression>
|
||||||
|
|
||||||
#include "GLCanvas.h"
|
#include "GLCanvas.h"
|
||||||
|
|
||||||
OpenGLInfo::OpenGLInfo(int& argc, char** argv) :
|
OpenGLVersionChecker::OpenGLVersionChecker(int& argc, char** argv) :
|
||||||
QApplication(argc, argv)
|
QApplication(argc, argv)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
bool OpenGLInfo::isValidVersion() {
|
bool OpenGLVersionChecker::isValidVersion() {
|
||||||
bool valid = true;
|
bool valid = true;
|
||||||
|
|
||||||
// Retrieve OpenGL version
|
// Retrieve OpenGL version
|
|
@ -1,5 +1,5 @@
|
||||||
//
|
//
|
||||||
// OpenGLInfo.h
|
// OpenGLVersionChecker.h
|
||||||
// interface/src
|
// interface/src
|
||||||
//
|
//
|
||||||
// Created by David Rowe on 28 Jan 2016.
|
// Created by David Rowe on 28 Jan 2016.
|
||||||
|
@ -9,17 +9,17 @@
|
||||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||||
//
|
//
|
||||||
|
|
||||||
#ifndef hifi_OpenGLInfo_h
|
#ifndef hifi_OpenGLVersionChecker_h
|
||||||
#define hifi_OpenGLInfo_h
|
#define hifi_OpenGLVersionChecker_h
|
||||||
|
|
||||||
#include <QApplication>
|
#include <QApplication>
|
||||||
|
|
||||||
class OpenGLInfo : public QApplication {
|
class OpenGLVersionChecker : public QApplication {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
OpenGLInfo(int& argc, char** argv);
|
OpenGLVersionChecker(int& argc, char** argv);
|
||||||
|
|
||||||
static bool isValidVersion();
|
static bool isValidVersion();
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // hifi_OpenGLInfo_h
|
#endif // hifi_OpenGLVersionChecker_h
|
|
@ -22,7 +22,7 @@
|
||||||
#include "AddressManager.h"
|
#include "AddressManager.h"
|
||||||
#include "Application.h"
|
#include "Application.h"
|
||||||
#include "InterfaceLogging.h"
|
#include "InterfaceLogging.h"
|
||||||
#include "OpenGLInfo.h"
|
#include "OpenGLVersionChecker.h"
|
||||||
#include "MainWindow.h"
|
#include "MainWindow.h"
|
||||||
|
|
||||||
int main(int argc, const char* argv[]) {
|
int main(int argc, const char* argv[]) {
|
||||||
|
@ -88,8 +88,8 @@ int main(int argc, const char* argv[]) {
|
||||||
// This is done separately from the main Application so that start-up and shut-down logic within the main Application is
|
// This is done separately from the main Application so that start-up and shut-down logic within the main Application is
|
||||||
// not made more complicated than it already is.
|
// not made more complicated than it already is.
|
||||||
{
|
{
|
||||||
OpenGLInfo openGLInfo(argc, const_cast<char**>(argv));
|
OpenGLVersionChecker openGLVersionChecker(argc, const_cast<char**>(argv));
|
||||||
if (!openGLInfo.isValidVersion()) {
|
if (!openGLVersionChecker.isValidVersion()) {
|
||||||
qCDebug(interfaceapp, "Early exit due to OpenGL version.");
|
qCDebug(interfaceapp, "Early exit due to OpenGL version.");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue