Search Unity

RELEASED FLOWFIRE Super Sampling SSAA - Visually best Anti Aliasing!

Discussion in 'Assets and Asset Store' started by Flow-Fire-Games, Jun 11, 2015.

  1. Stormbreaker

    Stormbreaker

    Joined:
    Aug 15, 2012
    Posts:
    161
    Here's an example screenshot from a render. The SSAA spits out a rendered image at 960*540 which uRecord then upscales resulting in poor image quality.

     
  2. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    We will have another go with it tomorrow and if its not resolvable on our part, then we will contact the uRecord authors and try to work something out together.
     
    wetcircuit and Stormbreaker like this.
  3. mittense

    mittense

    Joined:
    Jul 25, 2013
    Posts:
    168
    My sampling parameter keeps getting reset to 1.1 from the intended and set 2.0. :/
     
    Stormbreaker likes this.
  4. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    We will deplox a fix as soon as possible.

    Edit: Removed temp solution to fix, as fix is live
     
    Last edited: Jul 22, 2015
  5. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    Hotfix 1.2.1 live with fix of parameter resetting and of some Unity 4 Improvements.
    Our current focus for SSAA lies on uRecord compability.
     
    Stormbreaker and wetcircuit like this.
  6. Synapsy

    Synapsy

    Joined:
    Feb 6, 2015
    Posts:
    3
    Unfortunately, it doesn't work with render Textures.
    Also, it doesn't work with VRPanorama Asset (gives a black captures).
     
  7. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    SSAA already uses a RenderTexture.
    Since SSAA is not a pure Post Effect there won't be an easy way to ensure compatibility with all the other RenderTexture focused assets out there.
    However, you may access the High-Resolution Target via SSAA.internal_SSAA.RenderTexture.
    If you are interested in the output, a camera with a higher depth value, Clearflags: don't clear, Culling Mask: nothing and TargetTexture with your desired RenderTexture might be the solution.
     
  8. roycn

    roycn

    Joined:
    Dec 24, 2013
    Posts:
    7
    Hi! I have question SSAA can in mobile game (ios and android)? Have any test? thx
     
  9. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    It does work (tested with android). If you have frame rate issues keep in mind that SSAA is a fairly GPU heavy approach, you might want to settle with FXAA in this case.
     
  10. KWaldt

    KWaldt

    Joined:
    Nov 1, 2013
    Posts:
    127
    Hello there!

    I recently bought the asset and love the look of it!
    However, activating SSAA breaks a script of mine which uses things like "void OnMouseEnter()"--if I activate SSAA, the mouse is not registered, which is actually quite game breaking for me as I rely on this.
    Are you aware of this bug and is there a way to avoid it?

    Best Regards,
    Kristina Waldt
     
  11. Stormbreaker

    Stormbreaker

    Joined:
    Aug 15, 2012
    Posts:
    161
    Also using this with PopcornFX particles seems to cause the editor to crash :confused:
     
  12. gian-reto-alig

    gian-reto-alig

    Joined:
    Apr 30, 2013
    Posts:
    756
    Hi

    Just today I tried to add the SSAA Script to my game prototype...

    Can you help find out what is the reason that the image I am getting without SSAA:



    Is turning into this mess as soon as I activate the SSAA script:



    ?
    I tested all my other ImageEffects, deactivated them all, still the same result. I am using Unity 5.0 still btw, Pro version.

    Thanks for any help!


    Regards

    Gian-Reto
     

    Attached Files:

  13. Migueljb

    Migueljb

    Joined:
    Feb 27, 2008
    Posts:
    562
    This AA effect does wonders. Sharpens perfect up front and blurs perfect in the back. Looks great on desktop but freezes the camera in the Oculus Rift DK2. Does anyone know if this has been fixed for VR cameras? I've tried many image effects and this is the only one that freezes the oculus rift's camera to a halt. Im using version 1.2 of this. Any help would be greatly appreciated.

    Im using unity pro 5.1.2f1. Forward Renderer with Linear.
    Oculus Rift DK2 with all latest runtime and firmare installed.
    Using oculus utilities OVR player in scene.

    Thanks.
    -Miguel
     
  14. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    Hey everyone,

    we just wanted to let you know, that we are working on a major update for SSAA.

    The OnMouseEnter issue is new for us though it seems to be a side effect of a workaround supporting camera resolution related stuff like "Camera.ScreenToWorldPoint".
    We will look further into it but for now I'm afraid you will need to write your own OnMouseEnter.
    Please let us know (flowfire@inbox.com) if we can be of further assistance in this.

    @Stormbreaker: Is there anything logged in your Editor Log files?

    @Gian-Reto: Have you tried starting with an empty scene adding your objects one by one? How about your Camera setup?
    SSAA doesn't change your Objects rendering only the amount of pixels rendered.
    Do not hesitate to contact or make us builds available at flowfire@inbox.com.

    @Miguel: We are aware of an issue with Oculus misreading the frame buffer (Oculus does not set its desired output RenderTarget height and width to Unity Screen.width/height).
    We will address this in the upcoming update.
    Edit: Update 1.3 brings full oculus compatibility

    Thank you all for your patience and support!
     
    Last edited: Sep 8, 2015
    Tryz likes this.
  15. Tryz

    Tryz

    Joined:
    Apr 22, 2013
    Posts:
    3,402
    Looks awesome!

    I stumbled upon this and I'm looking forward to picking it up after the update. I'm interested in using it for work I'm doing with the Samsung Gear VR and Oculus Rift.
     
  16. Ben-BearFish

    Ben-BearFish

    Joined:
    Sep 6, 2011
    Posts:
    1,204
    Can anyone tell me how this performs in comparison to the SSAA implementation by @Chman . Also, is there a quality comparison?
     
  17. FPires

    FPires

    Joined:
    Jan 5, 2012
    Posts:
    151
    You linked to SMAA, not SSAA. They're completely different things.
    SMAA is a post-processing effect, pretty much the best post-processing algorithm there is before you go into temporal correction techniques. It's still limited by the same issues non-temporal post-processing AAs have, namely they fail at correcting temporal aliasing so they look good in screenshots but bad in motion. It's possible to implement a temporal version of SMAA in theory, but you would need access to information that Unity doesn't expose.

    SSAA will always be better than post-processing by a huge margin because it's sampling each pixel more than once, therefore increasing the overall precision of the information in each pixel instead of lowering it (which is what almost always happens in blur convolution matrices). In some cases, 2x SSAA might look slightly inferior to a good SMAA algorithm in a static image but will always look better in motion.

    SSAA is incredibly expensive and taxing compared to SMAA. The ideal compromise would be MSAA but Unity has chosen not to support MSAA in Deferred (even though it's technically doable in DX11). SMAA is more comparable to other post-processing effects, and is better than every other post-processing effect available in Unity by a lot. SSAA offers the best possible image theoretically at the cost of being very expensive to render.

    By the way, there are comparison images between SMAA and SSAA in the very link you posted.
     
    Last edited: Aug 11, 2015
    Ben-BearFish likes this.
  18. Chman

    Chman

    Unity Technologies

    Joined:
    Feb 6, 2010
    Posts:
    721
    Another compromise would be to use SSAA 2x on top of SMAA 1x. That's what I'm doing and it looks almost perfect without being too expensive (unless you're rendering at 4K+).
     
    overthere and Ben-BearFish like this.
  19. Ben-BearFish

    Ben-BearFish

    Joined:
    Sep 6, 2011
    Posts:
    1,204
    That was a typo, but thanks for the detailed information of the two techniques.
    @Chman Did you implement your own SSAA, or use someone else's SSAA?

    As far as I can tell, the Flowfire SSAA seems to be the best option currently available for Unity.
     
  20. Chman

    Chman

    Unity Technologies

    Joined:
    Feb 6, 2010
    Posts:
    721
    I have my own. But I don't want to hijack the original topic :)
     
    Ben-BearFish likes this.
  21. Ben-BearFish

    Ben-BearFish

    Joined:
    Sep 6, 2011
    Posts:
    1,204
    Understood. Thanks for the clarity.
     
  22. fakegood

    fakegood

    Joined:
    Oct 11, 2013
    Posts:
    31
    hello, can I know about the performance on mobile devices? or it is even meant for mobile devices?
     
  23. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    Hey,

    By nature it is not intended for mobile devices but if your game has enough performance left and if you use a smaller modifier it may work out fine, but it heavily depends on your game. A small modifier would have very little performance impact but also give not as much gain. (you can scale as much as you want, so it just depends on the scale, you can actually even scale negatively, increasing performance but decreasing resolution)
    The best and totally safe thing generally is giving the scale factor as option, so it can be scaled by the user depending on hardware.
     
    Last edited: Aug 14, 2015
  24. antonov_3d

    antonov_3d

    Joined:
    Jan 21, 2015
    Posts:
    28
    Hello, as soon as i start game screen goes to white gradually over 1 second
    this is my camera fx stack
    http://prntscr.com/866lvm
    and secondary camera
    http://prntscr.com/866lz9

    it seems your solution doesnt work if main camera has depth only flag
     
  25. eco_bach

    eco_bach

    Joined:
    Jul 8, 2013
    Posts:
    1,601
  26. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    @antonov Using SSAA on all your cameras will make it work as SSAA does not upscale your first cameras render target. The only Camera you might want to render without SSAA is World UI on top of everything else.
    The Read me is unfortunately a little unclear for multi-camera setups, we will try improving that in the future.

    have you tried the web viewer eco_bach? http://www.flowfiregames.com/#!ssaaviewer/c1thf
    Your unity answers thread seems to be deleted, but SSAA certainly helps a lot with Aliasing problems.
    You can turn it up very high if required. Have fun!
     
  27. 8Infinite8

    8Infinite8

    Joined:
    Jul 27, 2013
    Posts:
    112
    Hi this looks fantastic. I was wondering if there is a way to upscale the output resolution when saving .PNG Screenshot? I have a custom Screenshot Capture script that will do super scaling on the Game window and save an image to disk.

    This is used purely for beauty shots. So instead of a 2560x1270 (Maximize on Play from a 2560x1440 screen) output, it will be up scaled by 3 to 7680x3810. Or is there another way to do this?
     
  28. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    Hey 8Infinite8,
    Thank you very much. It is not possible to save a higher resolution Screenshot at the moment,
    it seems like a good idea though.
    Maybe your custom script will work with our upcoming Update (OVR and URecord seem to have similiar issues with SSAA). However, we might integrate something like this ourselves!

    Stay tuned
     
    Last edited: Sep 8, 2015
    8Infinite8 likes this.
  29. 8Infinite8

    8Infinite8

    Joined:
    Jul 27, 2013
    Posts:
    112
    That would be great. I would be happy to offer some development incentive offline if you're interested, being able to save out scaled images with SSAA would be very useful.

    Let me know.

    When you save out images, can your script check the folder location and add suffix to the next saved image without over writing the previous saved image?

    FYI you should charge more for this SSAA product. It's well worth more. In fact Unity should be paying interest in this.
     
  30. mittense

    mittense

    Joined:
    Jul 25, 2013
    Posts:
    168
    https://www.assetstore.unity3d.com/en/#!/content/533
     
  31. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    Hey guys, thanks for your continued support.

    We are uploading version 1.3 today, and ETA is in 3-4 days.

    1.3 will include various fixes and improvements and mainly Oculus OVR compatibility
    and support for other people using screen resolutions that differ from game resolutions.

    The next update will likely add increased screenshot functionality but main priority are your
    top requests as always!

    ------------------------------------------------------------------------------


    Some of the thew store images for better comparisons:





     
    Last edited: Sep 28, 2015
    8Infinite8 likes this.
  32. ptblk

    ptblk

    Joined:
    Mar 27, 2015
    Posts:
    57
    hi just bought this but getting an error when applied. Only have a single mesh in the scene

    RenderTexture.Create failed: width & height must be larger than 0
     
  33. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    Hey there,

    we noticed this error as well. In some cases Screen.width/height seems to be 0 in the first frame, in the upcoming Update SSAA uses a higher default value.
    If you still experience any issues then, using the new dynamic output resolution mode should do the trick.

    However, if anybody is able to regularly reproduce this issue please let us know!
     
  34. jonfinlay

    jonfinlay

    Joined:
    Aug 25, 2015
    Posts:
    535
    Hi, I've just bought this asset but every time I add it to the FPS camera and run, Unity crashes. I'm using Unity 5 Free. Thanks.

    I've just tested it UFPS's clean scene and it doesn't render the terrain. I'm using the lowest settings (1.1 multiplier).
     
    Last edited: Sep 6, 2015
  35. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    Is there a specific error message that you are getting ? Crashing Unity sounds rather odd. Maybe a conflict with another camera / rendering asset that you use ? Please send us some details to flowfire@inbox.com
     
  36. jonfinlay

    jonfinlay

    Joined:
    Aug 25, 2015
    Posts:
    535
    I'll try resetting the computer. I'm not using any other camera's or rendering assets, only using the default. I'm using UFPS. It doesn't give any error message, just crashes (Unity 5 has stopped responding).
     
  37. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    We just recently had someone saying the same coupled with UFPS. Maybe it is resolved with the upcoming patch, should be live any day / minute. Our UFPS tests were always running fine, but we will certainly will try finding a solution if the problem persists after the update. Does the task manager maybe indicate something ?
     
  38. jonfinlay

    jonfinlay

    Joined:
    Aug 25, 2015
    Posts:
    535
    I managed to find the problem with the UFPS, when I deactivated or deleted the Main Camera, it worked fine. However, after numerous tests I found if you removed or deactivated SSAA afer applying it, the camera doesn't render anything except a black screen and the GUI. When it works, the SSAA effect is good, just seems to me that the asset is extremely buggy in its current state.

    I've tested it again using a 2000 x 2000 and it seems to work, the reason why it crashed Unity initially could have been down to the fact that I hadn't optimised any object on the scene, which had lots of trees and grass. I have a i5 core with a 2GB graphics card and 8GB ram. It may simply have been too much for the hardware. Although it does seem strange that I can run it fine on my current map which has a few trees and mountains, again not optimised, and it runs at 1.5 multiplier without any lag, including a bloom effect.

    The reason I chose this asset was to give the end-user the option, if he had a good computer, to run at full graphics. I hadn't planned on using it myself in the development, only to test it.
     
  39. 8Infinite8

    8Infinite8

    Joined:
    Jul 27, 2013
    Posts:
    112
    Really looking forward to test this in VR.

    EDIT:

    Any idea on release date for the upgrade?
     
    Last edited: Sep 10, 2015
  40. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    @jonfinlay Handling with multi camera setups is improved with the 1.3 update, it should likely remove those annoyances, if there is still some strange behaviour left we will adress it right afterwards. SSAA is very simple to set up on single camera setups, on multi camera ones make sure both cameras have SSAA applied to work correctly.

    If problems remain with UFPS and similar setus after 1.3, we try to have these resolved with the upcoming patch so
    everything is fire and forget, just like using SSAA with a single camera setup.

    1.3 also brings improved documentation for those special cases

    The update was uploaded September 3, Unity approval usually ranges from 2-5 workdays for an update, it could really be any minute, but this is not in our hands. Hopefully today!
     
    Last edited: Sep 11, 2015
  41. XaneFeather

    XaneFeather

    Joined:
    Sep 4, 2013
    Posts:
    97
    Just realized that if you disable SSAA and run the scene, it defaults back to Nearest Neighbor and saves it.
     
  42. gurayg

    gurayg

    Joined:
    Nov 28, 2013
    Posts:
    269
    Got a quick question.
    Does SSAA results in a LDR image? If SSAA is the first component on a HDR enabled camera, what does the next Screen-Space effect gets after the SSAA?
    Thanks
     
  43. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    Hello guys, something sadly seems to not work out with the approval process of the 1.3 update we submitted the 3rd, so we just resubmitted the package.The approval usually takes between 2-4 days.

    XaneFeather, If i remember correctly then we fixed that with the 1.3 update, if we didnt then it will be included in a hotfix afterwards, thanks for the notice! @gurayg, Ill have to check with Alex when he is back home as I am not sure.

    Edit: Update 1.3 is now live
     
    Last edited: Sep 20, 2015
  44. jonfinlay

    jonfinlay

    Joined:
    Aug 25, 2015
    Posts:
    535
    Thanks for the update, it runs ok, but the image is far more blurry than before. Also, I'm getting this error message:

    GetRenderManager().GetCurrentCameraPtr() == m_Context->m_Camera
     
  45. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    We will look into this and deploy a fix as soon as possible, thanks for the notice!

    About the blurryness, that could be that you use an sampling algorithm that is not suited for the
    multiplier. (Per example Bilinear High and Lanczos High should look very blurry on low multiplicators)

    - Nearest Neighbor - Fastest, and with sharpest look and edges. (Recomm. Multiplier: 1-2)
    - Bilinear Sharper - compromise between the soft Bilinear and sharp NN (1-2)
    - Bilinear Default - a softer image (1.5-2)
    - Bilinear High - a softer image, optimized for high scaling (2-4)
    - Lanczos High - smoothest image, optimized for high scaling (2-4)
     
    Last edited: Sep 20, 2015
  46. zelmund

    zelmund

    Joined:
    Mar 2, 2012
    Posts:
    437

    can you please include that info into doc's?
     
  47. jonfinlay

    jonfinlay

    Joined:
    Aug 25, 2015
    Posts:
    535


    I was using what I'd been using before, a multiplier of 1.5 with Nearest Neighbour. However I've experimented with every different combination but the changes don't seem to affect what's on screen. I'm quite sure it's related to the error message I'm getting.
     
  48. zelmund

    zelmund

    Joined:
    Mar 2, 2012
    Posts:
    437
    you will not see changes until you go full screen mode. 2x - can see, but 3x - 4x can even reduce quality, if you trying to see effect in editor mode.
     
  49. Flow-Fire-Games

    Flow-Fire-Games

    Joined:
    Jun 11, 2015
    Posts:
    305
    @zelmund, that info is already included in the Docs

    @jonfinlay
    You have to press play for it to work, it will not affect your editor view unless Play mode is on.
    The error you are getting is not related to our SSAA code, it must come from something else, potentially having an issue with SSAA maybe, are you using another asset in combination that works with cameras ? Can you describe more in detail what you are doing ? That sounds very odd.
     
    Last edited: Nov 1, 2015
  50. jonfinlay

    jonfinlay

    Joined:
    Aug 25, 2015
    Posts:
    535
    After I created a new scene it's working again, the problem must have been with that scene. Thanks