diff options
author | Michael Brasser <michael.brasser@live.com> | 2017-04-18 09:07:07 -0500 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2017-08-07 13:56:05 +0000 |
commit | 432e27ae092397cb2154f48103e729852c38cf2d (patch) | |
tree | 12c9b108a6e85082d029da994af0f9c7e5ca8d4f /tests/auto/qmltest | |
parent | 5a6887ae8536c0b751e7b870ab629ecbf8784d22 (diff) |
Add very basic compressed texture support
Allow direct loading of pkm texture files into Image. This can
be extended to additional texture types, and then eventually
turned into a full plugin architexture.
[ChangeLog][Qt Quick] Allow direct loading of pkm texture files
into Image. For example: Image { source: "myImage.pkm" }
Change-Id: I1baed6c3e85a15752da8adc675482d874c9355ab
Task-number: QTBUG-59872
Task-number: QTBUG-29451
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Diffstat (limited to 'tests/auto/qmltest')
-rw-r--r-- | tests/auto/qmltest/image/logo.pkm | bin | 0 -> 32784 bytes | |||
-rw-r--r-- | tests/auto/qmltest/image/tst_image.qml | 9 |
2 files changed, 9 insertions, 0 deletions
diff --git a/tests/auto/qmltest/image/logo.pkm b/tests/auto/qmltest/image/logo.pkm Binary files differnew file mode 100644 index 0000000000..c0987c5c36 --- /dev/null +++ b/tests/auto/qmltest/image/logo.pkm diff --git a/tests/auto/qmltest/image/tst_image.qml b/tests/auto/qmltest/image/tst_image.qml index 6f2164363c..69ef4d1868 100644 --- a/tests/auto/qmltest/image/tst_image.qml +++ b/tests/auto/qmltest/image/tst_image.qml @@ -112,6 +112,11 @@ Item { fillMode: Image.TileHorizontally } + Image { + id: pkmImage + source: "logo.pkm" + } + TestCase { name: "Image" @@ -212,5 +217,9 @@ Item { compare(tileModes3.fillMode, Image.TileHorizontally) } + function test_pkmImage() { + compare(pkmImage.width, 256) + compare(pkmImage.height, 256) + } } } |