Unity Community


Page 4 of 7 FirstFirst ... 23456 ... LastLast
Results 61 to 80 of 137
  1. Unity Developer

    Posts
    877
    Quote Originally Posted by imaginaryhuman View Post
    Keely you said texture packing to a spritesheet is pro only? .... is there ANY atlas support for Free users, like rectangle based?
    Depends on what is your definition of atlas support. There are now two separate features regarding atlases:

    1. Sprite Packer (pro)
    2. Sprite Editor (free)

    They do different things. Actually they kinda do the opposite things of each other.

    Sprite Editor (free) is in the import pipeline. It takes texture as input and has sprite assets as output. Say you have ten sprites all on a single texture, Sprite Editor allows you to visually define where those sprites are (UV rects basically) and then import pipeline will spit out ten sprite sub-assets. You can then use these sprite assets in your game. We also offer something called automatic slicing or grid slicing in the editor, so that it is very fast operation workflow-wise. You can define these rects via the texture importer APIs too.

    Sprite Packer (pro) however does the opposite. It takes sprite assets as input and texture sheet as output. When you have pro, it doesn't really matter how you import your sprites (as singles or sheets), they will get repacked (unless you tell Unity you don't want to) when you build or when you go into the playmode. The result will be tighter than typical rect packing. Sprite Packer has no script APIs at the moment.

    So if you only have free, you need to have your sprites already in an texture atlas. You then use Sprite Editor to slice. If you happen to already have the metadata where the UV rects are, you can also create your own importer that spits out the sprite assets automatically.

    I think the bottom line is that with free version, you can import atlases, and it's easy to slice them to assets. For 1 sprite = 1 texture, you can make the packing yourself, but you need to operate on rects. With pro, you get automatic packing that doesn't really require any effort on your part and has the tightest packing evar.

    To clarify: Sprite assets are always sub-assets of a texture asset.
    Last edited by keely; 08-29-2013 at 08:43 AM.


  2. Location
    Virginia, USA
    Posts
    1,372
    Quote Originally Posted by keely View Post
    Attachment 65635

    Actually the packing algorithm we use for our automatic packing for sprites (note: will be pro only) is much much better when compared to the Texture2D.PackTextures(). Unfortunately we don't yet expose this as a public API yet, but maybe somewhere in the future.

    The difference is that while PackTextures() uses rects, we can now use complex shapes in our packing. This is because SpriteRenderer component actually doesn't render quads, but it renders a complex mesh that follows the contours of the alpha. For example if you had a circle shaped sprite, we render circle shaped mesh underneath. Main reason for this is to save fillrate, but it also means that while packing the sprites, we can actually pack the circle shape and not the quad shape.

    The end result is that depending on the shapes of your sprites, you get a lot tighter packing. Sometimes you save almost half the space when compared to the old one.
    Absolutely, fricking fantastic!!!! This'll significantly cut down the number of texture atlases I need and ease the pressure of the 50 Mb barrier.

    Questions:
    * Please support variable resolutions texture atlases at runtime. The diff between 3GS and iPad 3 is ... not small. At a minimum, the Texture packer (TP) should allow mip-mapping of the assets, where you can tell it easily what size asset to push to the GPU, BEFORE it tries to shove a 2048x2048 texture to the 3GS.
    * Can you expose the Shuriken API in code? So we can use it's awesomeness, programatically. Yes, this is an aside.
    * Can you explore BMFonts (or other font packers) in your 2D features? That'll be a huge hole if not supported.
    * Will the TP be integrated closely with the eventual GUI tools? I'd like the TP to feel uniform between the 2D sprites and GUI elements.

    Gigi.
    What Went Well - a Meditation on Gratitude and Happiness
    Good Sex, Great Marriage - Still The #1 Marriage App on iOS *** Also on Android!
    The Gratitude Habit - 1000 5-star reviews

    The Secret of Success? Try; Improve; Repeat- 'till too good to ignore.

  3. Unity Developer

    Posts
    877
    Quote Originally Posted by Gigiwoo2 View Post
    * Please support variable resolutions texture atlases at runtime.
    Nothing like this on the first release, but it makes a lot of sense. We just need to figure out the "Unity-way".

    Quote Originally Posted by Gigiwoo2 View Post
    * Can you expose the Shuriken API in code? So we can use it's awesomeness, programatically. Yes, this is an aside.
    * Can you explore BMFonts (or other font packers) in your 2D features? That'll be a huge hole if not supported.
    Don't have much info on these, sorry.

    Quote Originally Posted by Gigiwoo2 View Post
    * Will the TP be integrated closely with the eventual GUI tools? I'd like the TP to feel uniform between the 2D sprites and GUI elements.
    I'd rather not speculate too much on what the GUI will do, because so many things might still change. The new GUI will use the same import/packing/asset pipeline than the 2D with very very high probability, though. The current build already does this.


  4. Posts
    644
    Quote Originally Posted by keely View Post
    If anyone has any questions about the new 2D stuff, I'll be happy to answer.
    Will we be able to render images through script in a fast way, such as through the GL class?


  5. Posts
    28
    How the thing is working for the camera? Is there some "2D Camera" that setup the ortho cam with the right projection matrix for a WxH screen, to allow pixel perfect rendering?

    Also so kind of autosnap of sprite position at render time to avoid bad rasterization?

  6. Super Moderator
    Location
    Great Britain
    Posts
    9,656
    Regarding texture packing, for example 2D tiles and such - please offer padding to defeat artefacts with point filtering games etc. While we will be moving away from 2D later, we still think its a good thing to be aware of for unity.
    Currently working with Sony on our new
    PS4 and Vita game in Unity!

    This post is not representative of Simian Squared Ltd

  7. Quote Originally Posted by Gigiwoo2 View Post
    * Please support variable resolutions texture atlases at runtime. The diff between 3GS and iPad 3 is ... not small. At a minimum, the Texture packer (TP) should allow mip-mapping of the assets, where you can tell it easily what size asset to push to the GPU, BEFORE it tries to shove a 2048x2048 texture to the 3GS.
    In case you're not aware, there's "Texture Quality" in the QualitySettings. Can change to half-res. Might be enough for you.

    Quote Originally Posted by Aras View Post
    We played with both (Chipmunk as a ninjacamp experiment, then Box2D as another experiment). No big reasons for one vs. the other really, we just had to pick "one of them". Box2D has a better "track record" of being used in many more games; perhaps that's the only reason really. Both are very nice 2D physics engines.
    Ahh, I see.

    Cheers,
    -Jon

  8. Unity Developer

    Posts
    877
    Quote Originally Posted by Sirithang View Post
    How the thing is working for the camera? Is there some "2D Camera" that setup the ortho cam with the right projection matrix for a WxH screen, to allow pixel perfect rendering?
    Nothing for the camera for the 4.3. We might still do some last minute tweak, but more likely not.

    Quote Originally Posted by Sirithang View Post
    Also so kind of autosnap of sprite position at render time to avoid bad rasterization?
    4.3 ships with a shader that snaps to pixels.

  9. Unity Developer

    Posts
    877
    Quote Originally Posted by hippocoder View Post
    Regarding texture packing, for example 2D tiles and such - please offer padding to defeat artefacts with point filtering games etc. While we will be moving away from 2D later, we still think its a good thing to be aware of for unity.
    You can set the "extrude edges" value on the advanced texture import settings. This is "I want x pixels of padding on the mesh around my sprite, please".


  10. Posts
    1,426
    Lotta good suggestions in this thread. In particular, I'm interested in padding for the texture packing, BMFont support (bitmapped fonts, created with the BMFont program) and a smart 2D camera to make things easy.


  11. Location
    USA
    Posts
    3,097
    Do you have any information on performance, not including physics? Like if we have 1000 2d objects in the new system, will it possibly perform x% faster than any other third party solution due to faster internal code etc?
    - ImaginaryHuman -

    NEW Mouse Path Animator - Mouse movement recording/playback - only $15!
    NEW Animated Dissolves for Shader Forge - Starting at $10!
    NEW Refract2D - Realtime refractions, reflections, image-based lighting, image distortions - ON SALE $25!
    Also Gradient Shader Pack - Realtime-generated animatable gradients - $20.
    Also Shader Wizard - CG Shader Generator including photoshop-style multi-texturing - $20.
    Also Texture Helper - procedural texture/pixmap-handling scripts - $10.


  12. Location
    The House of The Mouse
    Posts
    1,393
    Quote Originally Posted by keely View Post
    We also offer something called automatic slicing or grid slicing in the editor, so that it is very fast operation workflow-wise. You can define these rects via the texture importer APIs too.
    Will it support existing sprite sheet definitions? For example, our pipeline uses TP already. Will it parse an existing sprite sheet and xml/plist?


  13. Posts
    28
    Quote Originally Posted by zombiegorilla View Post
    Will it support existing sprite sheet definitions? For example, our pipeline uses TP already. Will it parse an existing sprite sheet and xml/plist?
    He already answered that no, no particular import from metadata from 3rd party software, but there is a hook in the AssetImporter API, and that you can set subRect through script, so easy to wrote an editor script that do it when you import your spritesheet.

    My two cents : tons of free script on the net will do it two day after release. So much love in the Unity community.


  14. Location
    Northern VA, USA
    Posts
    547
    Unity Indie, Unity iPhone Basic, 27inch iMac, 17inch MacBook Pro, iPhone 2G, 3G, 3GS, iPhone 4, iPad and iPad 2 (yep got them all), also have latest Apple TV.


  15. Location
    Phoenix, AZ
    Posts
    184
    Quote Originally Posted by dingosmoov View Post
    +1 for Vectors
    Vectors are a dicey proposition, and not necessarily the best way to handle things for an engine designed around 3D rendering.

    The current rendering pipeline is built around using textures to define colors stretched across polygons. Adding vector support would be a low-level operation that would have to replace that functionality with vector graphics. It's possible, but it isn't easy, and it wouldn't blend very well with texture definitions.

    Personally I love vectors, and regularly use Inkscape for finishing illustrations. But to properly take advantage of vector graphics, you would have to build the rendering engine around them. Shoehorning support into an existing system wouldn't be enough.


  16. Location
    USA
    Posts
    3,097
    I'm not sure you know what you're talking about re vectors... they can be rendered either by breaking them up into triangles, which is the standard rendering unit of all graphics cards, or by rendering a single triangle with a special `curve` shader. True the GPU doesn't really generate vector shapes in their most native format (although perhaps that could be done with a DX11 tesselation shader), but they definitely can be rendered FAST in Unity without any low-level modification, and in support of texturing.

    In the new 2D unity tools, a sprite which has a custom mesh cutting out its shape is essentially a vector object with a texture applied, is it not?
    - ImaginaryHuman -

    NEW Mouse Path Animator - Mouse movement recording/playback - only $15!
    NEW Animated Dissolves for Shader Forge - Starting at $10!
    NEW Refract2D - Realtime refractions, reflections, image-based lighting, image distortions - ON SALE $25!
    Also Gradient Shader Pack - Realtime-generated animatable gradients - $20.
    Also Shader Wizard - CG Shader Generator including photoshop-style multi-texturing - $20.
    Also Texture Helper - procedural texture/pixmap-handling scripts - $10.


  17. Posts
    1,969
    I'd like to see if I could somehow use 3d models in 2D mode . I'm working on what is basically a 2d game with 3d models , but I'd really like better hit detection .
    http://beatquestgame.com

    Everyone makes a classic platformer , here's mine

    https://play.google.com/store/apps/d...QnJvc0xpdGUiXQ..

  18. Volunteer Moderator



    Location
    Copenhagen
    Posts
    5,297
    Quote Originally Posted by keithsoulasa View Post
    I'd like to see if I could somehow use 3d models in 2D mode . I'm working on what is basically a 2d game with 3d models , but I'd really like better hit detection .
    The new 2D system isn't exclusive. You will still be able to integrate 3D models. If you watch the Unite Keynote you can see that everything is still taking place in 3D, it's just the tools that are being streamlined for 2D functionality (and of course a lot of optimizations). But a mix of 2D/3D is still totally possible.


  19. Location
    ACT, Australia
    Posts
    65
    Well shit...There go my Simple Sprite sales


  20. Location
    Germany
    Posts
    192
    So.. Unity will get more Uni2D Features xD

    Will there be a way to animate sprites via bones too?

Page 4 of 7 FirstFirst ... 23456 ... LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •