mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 00:36:47 +02:00
Added Script command to test if GPU memory size is stable.
This commit is contained in:
parent
f926298020
commit
303dabd93c
3 changed files with 15 additions and 1 deletions
|
@ -468,6 +468,8 @@ public slots:
|
||||||
|
|
||||||
QString getGraphicsCardType();
|
QString getGraphicsCardType();
|
||||||
|
|
||||||
|
bool gpuTextureMemSizeStable();
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void onDesktopRootItemCreated(QQuickItem* qmlContext);
|
void onDesktopRootItemCreated(QQuickItem* qmlContext);
|
||||||
void onDesktopRootContextCreated(QQmlContext* qmlContext);
|
void onDesktopRootContextCreated(QQmlContext* qmlContext);
|
||||||
|
@ -562,7 +564,6 @@ private:
|
||||||
bool importFromZIP(const QString& filePath);
|
bool importFromZIP(const QString& filePath);
|
||||||
bool importImage(const QString& urlString);
|
bool importImage(const QString& urlString);
|
||||||
|
|
||||||
bool gpuTextureMemSizeStable();
|
|
||||||
int processOctreeStats(ReceivedMessage& message, SharedNodePointer sendingNode);
|
int processOctreeStats(ReceivedMessage& message, SharedNodePointer sendingNode);
|
||||||
void trackIncomingOctreePacket(ReceivedMessage& message, SharedNodePointer sendingNode, bool wasStatsPacket);
|
void trackIncomingOctreePacket(ReceivedMessage& message, SharedNodePointer sendingNode, bool wasStatsPacket);
|
||||||
|
|
||||||
|
|
|
@ -1026,6 +1026,12 @@ bool EntityScriptingInterface::isLoaded(const QUuid& id) {
|
||||||
return toReturn;
|
return toReturn;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool EntityScriptingInterface::isTextureLoadingComplete() {
|
||||||
|
bool result;
|
||||||
|
QMetaObject::invokeMethod(qApp, "gpuTextureMemSizeStable", Qt::DirectConnection, Q_RETURN_ARG(bool, result));
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
bool EntityScriptingInterface::isAddedEntity(const QUuid& id) {
|
bool EntityScriptingInterface::isAddedEntity(const QUuid& id) {
|
||||||
bool toReturn = false;
|
bool toReturn = false;
|
||||||
_entityTree->withReadLock([&] {
|
_entityTree->withReadLock([&] {
|
||||||
|
|
|
@ -395,6 +395,13 @@ public slots:
|
||||||
*/
|
*/
|
||||||
Q_INVOKABLE bool isLoaded(const QUuid& id);
|
Q_INVOKABLE bool isLoaded(const QUuid& id);
|
||||||
|
|
||||||
|
/**jsdoc
|
||||||
|
* Check whether all textures have been loaded.
|
||||||
|
* @function Entities.areTexturesLoaded
|
||||||
|
* @returns {boolean} <code>true</code> texture memory usage is not increasing <code>false</code>.
|
||||||
|
*/
|
||||||
|
Q_INVOKABLE bool isTextureLoadingComplete();
|
||||||
|
|
||||||
/**jsdoc
|
/**jsdoc
|
||||||
* Check if there is an object of a given ID.
|
* Check if there is an object of a given ID.
|
||||||
* @function Entities.isAddedEntity
|
* @function Entities.isAddedEntity
|
||||||
|
|
Loading…
Reference in a new issue