mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 03:24:00 +02:00
only force youtube web entities to 30 FPS
This commit is contained in:
parent
2ceb3d85bd
commit
d18936ea18
1 changed files with 8 additions and 1 deletions
|
@ -113,7 +113,14 @@ bool RenderableWebEntityItem::buildWebSurface(QSharedPointer<EntityTreeRenderer>
|
|||
|
||||
// FIXME, the max FPS could be better managed by being dynamic (based on the number of current surfaces
|
||||
// and the current rendering load)
|
||||
_webSurface->setMaxFps(30);
|
||||
|
||||
// We special case YouTube URLs since we know they are videos that we should play with at least 30 FPS.
|
||||
if (QUrl(_sourceUrl).host().endsWith("youtube.com", Qt::CaseInsensitive)) {
|
||||
_webSurface->setMaxFps(30);
|
||||
} else {
|
||||
_webSurface->setMaxFps(10);
|
||||
}
|
||||
|
||||
|
||||
// The lifetime of the QML surface MUST be managed by the main thread
|
||||
// Additionally, we MUST use local variables copied by value, rather than
|
||||
|
|
Loading…
Reference in a new issue