Adding support for multiple images in AnimatedImageVisual 72/136672/9
authorDavid Steele <david.steele@samsung.com>
Wed, 28 Jun 2017 12:40:23 +0000 (13:40 +0100)
committerDavid Steele <david.steele@samsung.com>
Fri, 14 Jul 2017 10:53:05 +0000 (11:53 +0100)
commit46322a558e537267a6d3c48630c45afca91b5e27
treefc62ac3aa7d1c192f31b16bd5d91a00853e49b08
parentd26f555fd84d43b0a3e650c66a0e626e841dd9c6
Adding support for multiple images in AnimatedImageVisual

As well as supporting animated GIF, the animated image visual also
supports animating between a number of images.

This can be done using a property map containing the following:

{
   "url":[ "url1", "url2", "url3", "url4", "url5" ],
   "batchSize" : 3,
   "cacheSize" : 4,
   "frameDelay" : 100
}

The cache size is the total number of images that will be loaded at any one time;
the batch size is the maximum number of images it will attempt to load before displaying.
If the cache size is smaller than the batch size, it is increased to match. If either
are larger than the number of urls, they are reduced to match.

As soon as the visual is created, it will start loading up to batchSize urls into the
cache. After each frame has completed, it will start loading the next batch, etc,
until the cache is full. After the next frame, it will load only the next URL into
the cache.

If at any time, the next image is not ready, it will wait for the loading to complete
before displaying and triggering the next batch/frame load, but will not reset the timer.

Change-Id: Iccd59768aec814ab3b73fb7b817e45b95299b2c2
Signed-off-by: David Steele <david.steele@samsung.com>
41 files changed:
automated-tests/resources/application-icon-20.png [new file with mode: 0644]
automated-tests/resources/application-icon-21.png [new file with mode: 0644]
automated-tests/resources/application-icon-22.png [new file with mode: 0644]
automated-tests/resources/application-icon-23.png [new file with mode: 0644]
automated-tests/resources/application-icon-24.png [new file with mode: 0644]
automated-tests/resources/application-icon-25.png [new file with mode: 0644]
automated-tests/resources/application-icon-26.png [new file with mode: 0644]
automated-tests/resources/application-icon-27.png [new file with mode: 0644]
automated-tests/resources/application-icon-28.png [new file with mode: 0644]
automated-tests/resources/application-icon-29.png [new file with mode: 0644]
automated-tests/resources/application-icon-30.png [new file with mode: 0644]
automated-tests/src/dali-toolkit-internal/utc-Dali-TextureManager.cpp
automated-tests/src/dali-toolkit/CMakeLists.txt
automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-gl-abstraction.cpp
automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-gl-abstraction.h
automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-event-thread-callback.cpp
automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-event-thread-callback.h
automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-timer.cpp
automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-timer.h
automated-tests/src/dali-toolkit/utc-Dali-AnimatedImageVisual.cpp [new file with mode: 0644]
automated-tests/src/dali-toolkit/utc-Dali-Visual.cpp
dali-toolkit/devel-api/visuals/image-visual-properties-devel.h
dali-toolkit/internal/controls/image-view/image-view-impl.cpp
dali-toolkit/internal/controls/image-view/image-view-impl.h
dali-toolkit/internal/file.list
dali-toolkit/internal/visuals/animated-image/animated-image-visual.cpp
dali-toolkit/internal/visuals/animated-image/animated-image-visual.h
dali-toolkit/internal/visuals/animated-image/fixed-image-cache.cpp [new file with mode: 0644]
dali-toolkit/internal/visuals/animated-image/fixed-image-cache.h [new file with mode: 0644]
dali-toolkit/internal/visuals/animated-image/image-cache.cpp [new file with mode: 0644]
dali-toolkit/internal/visuals/animated-image/image-cache.h [new file with mode: 0644]
dali-toolkit/internal/visuals/animated-image/rolling-image-cache.cpp [new file with mode: 0644]
dali-toolkit/internal/visuals/animated-image/rolling-image-cache.h [new file with mode: 0644]
dali-toolkit/internal/visuals/image/image-visual.cpp
dali-toolkit/internal/visuals/image/image-visual.h
dali-toolkit/internal/visuals/texture-manager.cpp
dali-toolkit/internal/visuals/texture-upload-observer.h
dali-toolkit/internal/visuals/visual-factory-impl.cpp
dali-toolkit/internal/visuals/visual-string-constants.cpp
dali-toolkit/internal/visuals/visual-string-constants.h
dali-toolkit/public-api/visuals/image-visual-properties.h