Search Unity

WebP format... needed

Discussion in 'General Graphics' started by patrikspacek, Aug 1, 2016.

  1. patrikspacek

    patrikspacek

    Joined:
    Apr 10, 2014
    Posts:
    13
    Hi Folks,

    does anyone has WebP plugin for Unity? I have all images in this format and I need to add it to my project.

    Thanks
     
  2. fffMalzbier

    fffMalzbier

    Joined:
    Jun 14, 2011
    Posts:
    3,276
    There is a project for supporting webp in unity (did not test it) but its seems to be work in progress
    https://github.com/octo-code/webp-unity3d

    Option B: how about converting them to another format?
    You could use the free image viewer irfanview to batch convert them all.
    http://www.irfanview.de/
    (You may need the all plugins package in addition to read the WebP Files.)
    Converting them to png should do fine.
     
    Last edited: Aug 2, 2016
  3. patrikspacek

    patrikspacek

    Joined:
    Apr 10, 2014
    Posts:
    13
    Thanks a lot! I will check that out.
    I would like to keep them in webp format, the size is enormously different. 5GB > 800mb
     
  4. Eric5h5

    Eric5h5

    Volunteer Moderator Moderator

    Joined:
    Jul 19, 2006
    Posts:
    32,401
    Note that Unity doesn't use the original format for anything other than the initial import. Whether you have images in WebP format or TGA or PSD or anything else is irrelevant in the build. The only thing it would have any effect on is project size, but considering you can get 4TB hard drives for not much over $100 these days, that seems mostly irrelevant. Storage is cheap and plentiful, but your time is not—it's generally recommended to use PSD format since you can make edits very quickly and don't need to bother with exporting and so on.

    --Eric
     
    zakirshikhli likes this.
  5. patrikspacek

    patrikspacek

    Joined:
    Apr 10, 2014
    Posts:
    13
    The Webp plugin doesnt work... :eek:( We will search more....

    Eric: thanks, but that's not solution for me.
     
  6. probigi

    probigi

    Joined:
    Sep 24, 2014
    Posts:
    6
    Hello!
    Does anyone know WebP plugin which works in WebGL??? I really need it. I've already tried this plugin https://github.com/octo-code/webp-unity3d . But this plugin has an error in WebGL:
    Code (JavaScript):
    1. uncaught exception: abort("To use dlopen, you need to use Emscripten's linking support, see https://github.com/kripken/emscripten/wiki/Linking") at jsStackTrace
    I think this means need to rebuild plugin with some fixes to make it works on WebGL. But I don't know how. I will appreciate any help with this.
    Thank you!
     
  7. andymads

    andymads

    Joined:
    Jun 16, 2011
    Posts:
    1,614
    It depends how you use the images. I have a mobile puzzle game with a lot of 512x512 images. I originally had them as texture assets (PVRTC) with each texture being 128k. To reduce the app size I changed them to be raw jpg files (all are smaller than 128k) in the streaming assets folder which were loaded in as 32 bit RGBA textures as required. This isn't a big deal memory wise as there's only ever 1 texture loaded at a time. I'm now just tweaking the compression quality in order to further reduce the app size.
     
    AnomalusUndrdog likes this.
  8. djarcas

    djarcas

    Joined:
    Nov 15, 2012
    Posts:
    246
    It's 2023, why doesn't Unity understand Webp files yet?
     
    qiqiqi, lu526284266 and BaaWolf like this.