aboutsummaryrefslogtreecommitdiffstats
path: root/src/particles
diff options
context:
space:
mode:
authorLaszlo Agocs <laszlo.agocs@qt.io>2020-04-07 16:02:10 +0200
committerLaszlo Agocs <laszlo.agocs@qt.io>2020-04-28 11:46:27 +0200
commitd59e12a329e6a2127fd43e438cbfe9f750c646fc (patch)
tree58b3ea6c94cfcc26f6e473145b7dabccdcec3bea /src/particles
parentc2de5643cd4f1b8d8b10e2bb62fdf95f12fdd9e3 (diff)
Move updateRhiTexture and co. to QSGTexture
Use a more descriptive name, commitTextureOperations() in order to avoid confusion with QSGDynamicTexture::updateTexture() which has nothing to do with this. With this the QSGTexture interface has all 5.14 pending changes done (changes that were plumbed via ugly hacks due to having had to deal with binary compatibility). The awful enforcing of subclassing QSGTexturePrivate for each and every QSGTexture subclass is now eliminated. Purging the direct OpenGL code path will involve removing QSGTexture functions like textureId(), bind(), updateBindOptions(). With this patch we now we have all the equivalents (or, in some cases, spiritual successors) in place. Task-number: QTBUG-82997 Change-Id: I7a831f982070c52abc7a36604130a1110d14ff9c Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Diffstat (limited to 'src/particles')
-rw-r--r--src/particles/qquickimageparticle.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/particles/qquickimageparticle.cpp b/src/particles/qquickimageparticle.cpp
index ce7e99a3a0..f2e3715061 100644
--- a/src/particles/qquickimageparticle.cpp
+++ b/src/particles/qquickimageparticle.cpp
@@ -221,10 +221,10 @@ public:
{
ImageMaterialData *state = static_cast<ImageMaterial *>(newMaterial)->state();
if (binding == 2) {
- state->colorTable->updateRhiTexture(renderState.rhi(), renderState.resourceUpdateBatch());
+ state->colorTable->commitTextureOperations(renderState.rhi(), renderState.resourceUpdateBatch());
*texture = state->colorTable;
} else if (binding == 1) {
- state->texture->updateRhiTexture(renderState.rhi(), renderState.resourceUpdateBatch());
+ state->texture->commitTextureOperations(renderState.rhi(), renderState.resourceUpdateBatch());
*texture = state->texture;
}
}
@@ -362,7 +362,7 @@ public:
{
ImageMaterialData *state = static_cast<ImageMaterial *>(newMaterial)->state();
if (binding == 1) {
- state->texture->updateRhiTexture(renderState.rhi(), renderState.resourceUpdateBatch());
+ state->texture->commitTextureOperations(renderState.rhi(), renderState.resourceUpdateBatch());
*texture = state->texture;
}
}
@@ -529,10 +529,10 @@ public:
{
ImageMaterialData *state = static_cast<ImageMaterial *>(newMaterial)->state();
if (binding == 2) {
- state->colorTable->updateRhiTexture(renderState.rhi(), renderState.resourceUpdateBatch());
+ state->colorTable->commitTextureOperations(renderState.rhi(), renderState.resourceUpdateBatch());
*texture = state->colorTable;
} else if (binding == 1) {
- state->texture->updateRhiTexture(renderState.rhi(), renderState.resourceUpdateBatch());
+ state->texture->commitTextureOperations(renderState.rhi(), renderState.resourceUpdateBatch());
*texture = state->texture;
}
}
@@ -682,7 +682,7 @@ public:
{
ImageMaterialData *state = static_cast<ImageMaterial *>(newMaterial)->state();
if (binding == 1) {
- state->texture->updateRhiTexture(renderState.rhi(), renderState.resourceUpdateBatch());
+ state->texture->commitTextureOperations(renderState.rhi(), renderState.resourceUpdateBatch());
*texture = state->texture;
}
}
@@ -830,7 +830,7 @@ public:
{
ImageMaterialData *state = static_cast<ImageMaterial *>(newMaterial)->state();
if (binding == 1) {
- state->texture->updateRhiTexture(renderState.rhi(), renderState.resourceUpdateBatch());
+ state->texture->commitTextureOperations(renderState.rhi(), renderState.resourceUpdateBatch());
*texture = state->texture;
}
}