Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Sprite/Texture Packer, Unity v5 ?

Discussion in '2D' started by J9383731, Mar 4, 2015.

  1. J9383731

    J9383731

    Joined:
    Nov 5, 2011
    Posts:
    26
    Is there a built in Texture Atlas Builder in Unity v5? I see sprite packer, but not clear how it's used. Doc's seem a bit vague. Or, do I need to use 2D toolkit for this?
     
  2. orb

    orb

    Joined:
    Nov 24, 2010
    Posts:
    3,033
    You're in the right neighbourhood :)

    Sprite Packer is the atlas/sprite sheet builder, but choosing where sprites go is done in each image's inspector, via Packing Tag. You can select all the sprites you want to put into one sheet and give them the same tag, then the Pack button in the packer window will assemble as many sheets as it thinks is necessary.

    The Sprite Editor button on each image lets you slice existing sheets automatically or as a grid, and change the pivot point on individual sprites.
     
    theANMATOR2b likes this.
  3. J9383731

    J9383731

    Joined:
    Nov 5, 2011
    Posts:
    26
    So, I filled in the Packing Tag, now what? Nothing else happens and I cannot drag my sprites into the Sprite Packer. Clicking "Pack" does nothing -- are you missing a step? Are there official instructions somewhere? Maybe a Youtube?
     
  4. orb

    orb

    Joined:
    Nov 24, 2010
    Posts:
    3,033
    There's no dragging involved. If it has made atlases, you should see them in the packer window. The only steps are to have sprites, tag them and pack.
     
  5. J9383731

    J9383731

    Joined:
    Nov 5, 2011
    Posts:
    26
    How can I tell if it worked? PS. I'm using the Personal Edition, if that matters?
     
  6. orb

    orb

    Joined:
    Nov 24, 2010
    Posts:
    3,033
    If it worked there should be atlases showing in the Sprite Packer window :)
     
  7. J9383731

    J9383731

    Joined:
    Nov 5, 2011
    Posts:
    26
    There aren't. But I don't know what it wouldn't work. Seems either that it's not supported in the Personal Edition or a Bug.
     
  8. J9383731

    J9383731

    Joined:
    Nov 5, 2011
    Posts:
    26
    8 images, import Texture Type: Sprite (2D and UI), Sprite Mode: Single, Packing Tag: Test, Pixels Per Unit: 1, Pivot: Center, Generate Mip Maps (unchecked), Filter Mode: Point, Max Size: 8192 (changed from 1024 to see if mattered, doesn't), Format: True Color.

    I clicked PACK in the Sprite Packer and clicked PLAY. Draw calls are still what they were before I attempted to Pack. Looking at Sprite Packer during and after run, nothing there.
     
  9. orb

    orb

    Joined:
    Nov 24, 2010
    Posts:
    3,033
  10. J9383731

    J9383731

    Joined:
    Nov 5, 2011
    Posts:
    26
    Always Enabled is what is selected (has been selected, didn't need to change)
     
  11. orb

    orb

    Joined:
    Nov 24, 2010
    Posts:
    3,033
    The max size only affects the maximum size the imported image should have. It's useful for different sizes if you have a mobile+desktop project.
     
  12. orb

    orb

    Joined:
    Nov 24, 2010
    Posts:
    3,033
    Dunno what the problem could be then :/
     
  13. J9383731

    J9383731

    Joined:
    Nov 5, 2011
    Posts:
    26
    Doesn't work.
     
  14. SiegfriedCroes

    SiegfriedCroes

    Joined:
    Oct 19, 2013
    Posts:
    569
    Exactly the same with me... Wanted to try the Sprite Packer, enabled it, gave my sprites a tag but nothing is appearing in the Sprite Packer window, the "Pack" button does nothing... Hope someone can tell what we're doing wrong :)
     
  15. ldaughtry

    ldaughtry

    Joined:
    Oct 30, 2012
    Posts:
    38
    Same here. Sprite Packing is Always Enabled, Packing tags are set, and if I tell it to Pack in the Sprite Packer window it processes something for a while. But nothing shows up in the Sprite Packer window when it's done. The atlas drop down is blank and I don't see any atlas folder under the library folder.
     
  16. medvedya2012

    medvedya2012

    Joined:
    May 27, 2014
    Posts:
    41
    Right now, I've tested Sprite packer with Unity Pro and Unity Personal, It is working.
     
  17. ldaughtry

    ldaughtry

    Joined:
    Oct 30, 2012
    Posts:
    38
    An update...

    If I take the same content, start a new project and use the same settings, all the atlas functionality works. Which leads me to believe some third party element in my project is preventing it from working. My money is on EZGui as that is the UI framework that has clashed with the naming conventions in the new UI.

    I'm going to do a bit more research.