2

I have converted a sequence of images to WebP, and I want to compile them into an animation. I downloaded libwebp, but it's a tar.gz archive and I don't know how to install those.

Is there another way to create an animated WebP file some other way?

  • a .tar.gz is not a package to be installed, it's an archive (much like a .zip). You can read about how to unarchive them with the man page (man 1 tar). – HalosGhost Jul 10 '14 at 5:04
  • Which is what I wrote. I know it's an archive. I don't know how to make tar.gz's work at the moment and am wondering if there is some other solution. – user8547 Jul 10 '14 at 5:43
  • To what are you referring? – HalosGhost Jul 10 '14 at 5:46
  • Are you a troll? If I want to know how to use tar.gz files I'll post a question specifically about that. – user8547 Jul 10 '14 at 5:54
  • 2
    Why are you against trying to unarchive the tarball and use libwebp? Also, you haven't told us what distro you're using, so if there is a package for your system, we can't tell you how to install it. – HalosGhost Jul 10 '14 at 5:56
3

What you have is an archive.

Linux has a massive manual with nearly every command right at your fingertips. These are called the man pages. To use man command, and it will give you everything on how to use it. In your case, you want tar to unarchive your file. To see how to do this, man 1 tar, or simply man tar will show you all of the options for archiving and unarchiving. The tar command is one that you'll use a lot, so it is helpful to know some of these and know where the man pages are.

Anyway, the version of libwebp that I found on google was 0.4.0, so once I unarchive it, use cd libwebp-0.4.0 to change to that directory.

Then according to the readme (less README), it says to install use:

./configure
make
make install

you may need to put sudo in front of the last command and it should install the library.

Now, you didn't say which distribution of Linux you are using, but I wouldn't be too surprised if the library is already installed.

If you don't feel comfortable building software, yet, I would recommend looking at your distribution's repository.

To install in ubuntu from the repo: sudo apt-get install libwebp

Once it is installed, you can use cwebp to compress your image. dwebp will decode it, vwebp will let you view.

Once you have your webp images, you want webpmux to create your animation. I haven't fully figured out how to use it effectively, but to create a webp animation you can:

The use format according to the man pages is:
webpmux -frame file_i.webp +di[+xi+yi[+mi[bi]]]
file_i is the ith frame. 'di' is the pause duration, so how long on that frame.
'xi', and 'yi' are the x and y offset for the frame.
'mi' is the how the frame is to be disposed. 0 = None, 1 = Background
'bi' is the blending method for the frame: +b = Blend -b = No Blend

The man pages can describe it in more depth. I recommend giving them a read. To see them use man webpmux, man cwebp, and man dwebp.

You will also find an example of how to use each in the man pages.

Good luck.

Personally, unless you have a reason for using the webp format, I'd use another animation video encoding format (GIF, webm, etc...) which can be made with graphical tools like openshot or gimp.

  • I find it unfortunate that you explained how to untar the file. Posters like this will never learn if they are fed answers which they could otherwise learn through valid and simple research (e.g., reading the man page). – HalosGhost Jul 10 '14 at 6:10
  • Yes, but it will come in time. I remember when I first switched from Windows, and wanted everything to just work since I needed the machine to do work. It wasn't easy, especially since I hadn't ever seen or heard of the man pages, and having people yelling about me not using them didn't help. They will have a lot of commands to learn, and it will come in time. It is a lot easier to learn when your workspace works with you too. – Evan Jul 10 '14 at 6:22
  • Note that my comment recommending the man page to read was not inflammatory or in any way discouraging. Were you to replace the opening of your answer with something like "see man 1 tar to learn how to use tar. Once you have it decompressed…" I would certainly give this post a +1. – HalosGhost Jul 10 '14 at 6:25
  • If tar weren't so useful, I'd be a little more hesitant to change it, but it is. – Evan Jul 10 '14 at 6:35
  • Haha, I understand your compulsion. I was not trying to convince you to change your answer; simply let you know that I thought the answer was thorough and deserving of praise, but not something I was willing to +1. Edit: I noticed you edited your answer; and I have +1'd your post. – HalosGhost Jul 10 '14 at 6:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.