Skip to content

Commit

Permalink
animated-gif: doc++, formatting, add forgotten image.
Browse files Browse the repository at this point in the history
  • Loading branch information
mosra committed Apr 9, 2020
1 parent 54aacf9 commit 76cab3b
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion doc/animated-gif.dox
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
namespace Magnum {
/** @page examples-animated-gif Animated GIF
@brief Playing back an animated GIF. On the GPU or in a terminal.
@m_since_latest_{examples}

@m_footernavigation

Expand All @@ -52,7 +53,7 @@ is bundled in the repository, see the links below.

@m_class{m-block m-primary}

@thirdparty This example bundles the *Newtons cradle animation book* image by
@thirdparty This example bundles the *Newton's cradle animation book* image by
DemonDeLuxe (Dominique Toussaint), CC BY-SA 3.0, https://commons.wikimedia.org/w/index.php?curid=3717500

@section examples-animated-gif-source Source
Expand Down
Binary file added doc/animated-gif.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 2 additions & 1 deletion src/animated-gif/AnimatedGifExample.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,8 @@ AnimatedGifExample::AnimatedGifExample(const Arguments& arguments):
state (in case this is an animated GIF). Convert them to floats and set
up a player to trigger a redraw. */
if(importer->importerState()) {
const auto frameDelays = Containers::arrayView(reinterpret_cast<const Int*>(importer->importerState()), imageCount);
const auto frameDelays = Containers::arrayView(
reinterpret_cast<const Int*>(importer->importerState()), imageCount);

Containers::Array<std::pair<Float, Int>> frames{std::size_t(imageCount)};
Float frameTime = 0.0f;
Expand Down

0 comments on commit 76cab3b

Please sign in to comment.