Search Unity

Alloy Physical Shader Framework Version 3 For Unity 5

Discussion in 'Assets and Asset Store' started by xenius, Mar 2, 2015.

  1. Deleted User

    Deleted User

    Guest

    @AlteredPlanet
    We had to disable it by default, since Unity would stop rendering skinned meshes with an instancing shader. Supposedly they've fixed that in the most recent release, but I haven't had time to test it.

    For the time being, the way to enable instancing in Alloy is to open the code editor (Visual Studio, Monodevelop, etc), hit Ctrl+Shift+H, do a mass replace of "//#pragma multi_compile_instancing" with "#pragma multi_compile_instancing", hit Ctrl+Shift+S, go back to the Unity editor, and wait for all the shaders to recompile.
     
  2. AlteredPlanets

    AlteredPlanets

    Joined:
    Aug 12, 2013
    Posts:
    455
    • Objects that use lightmaps, or are affected by different light or reflection probes, can’t be instanced.
    does this effect its usage?
     
  3. AlteredPlanets

    AlteredPlanets

    Joined:
    Aug 12, 2013
    Posts:
    455
    5.4.1 was just released has it been tested in there yet?
     
  4. Deleted User

    Deleted User

    Guest

    Okay, I finally got some time to try it, and it does appear to work now. Unity FINALLY eliminated that annoying error for instancing shaders on skinned meshes.
     
    elbows, Crossway and punk like this.
  5. AlteredPlanets

    AlteredPlanets

    Joined:
    Aug 12, 2013
    Posts:
    455
    Great:)
    Does it work with Light probes or reflection probes, also when does full alloy support for instancing become ready to use?
     
  6. Deleted User

    Deleted User

    Guest

    @AlteredPlanet
    It has the same restrictions as any other instance shader in Unity. To enable it, you must do a mass replace of the line "//#pragma multi_compile_instancing" with "#pragma multi_compile_instancing" in the shader files.
     
  7. Crossway

    Crossway

    Joined:
    May 24, 2016
    Posts:
    507
    They increased keywords limitation with Unity 5.5 beta versions, so I already moved to 5.5 but Alloy doesn't work with Unity 5.5, there will be any update soon?
     
  8. Deleted User

    Deleted User

    Guest

    @Crossway
    We're going to wait until the beta is more stable before we start porting to 5.5. At the very least, we want to get Alloy 3.4.3 out the door before we make the switch.
     
    punk and Crossway like this.
  9. Crossway

    Crossway

    Joined:
    May 24, 2016
    Posts:
    507
    Unity 5.5 features are cool! lots of old issues with Unity solved in 5.5. bugs like shadow and object flickering, keyword limitation. so please support this sooner thanks.
     
  10. istavang

    istavang

    Joined:
    Jan 17, 2015
    Posts:
    19
    Annoing ....Why is always alloy one step behind , getting pink mat in 5.5 when is Alloy getting 5.5 updatet ? thanks Dan
     
    Last edited: Sep 14, 2016
  11. Crossway

    Crossway

    Joined:
    May 24, 2016
    Posts:
    507
    I've captured a video of my problem with heavily highlighted area when using Alloy shading.
    When I select Unity default shading it's looks correct and nature but after using Alloy Deferred Skin Shading on the graphic section it like this (Please watch the video)

     
  12. Elecman

    Elecman

    Joined:
    May 5, 2011
    Posts:
    1,371
    I want to create a light lens effect like from the (real) picture below.

    light lens.JPG

    I want to do this with a flat plane and a normal map. The glass doesn't need to be transparent and overall it doesn't need to be too accurate.

    What shader/settings would be the cheapest way to do this? I tried to simply set the shader to full smooth and full metal but that looks too much like polished metal (surprise). The glass shader is probably not optimized for this use case.

    Any thoughts?
     
  13. StaffanEk

    StaffanEk

    Joined:
    Jul 13, 2012
    Posts:
    380
    What diffuse color would you like to have? If it's metal there won't be a diffuse. If it's dielectric and if you only want the reflection, the glass will be black.

    You have to use a transparent material. There is no way around it unless you use something like this.
     
  14. xenius

    xenius

    Joined:
    Sep 30, 2010
    Posts:
    523
    Howdy Folks. I'm happy to announce

    Alloy 3.4.3 for Unity 5.4+ is live on the Store

    So we've got some new features, and new accommodations for those of you doing VR work who need to manage perf. overhead even more obsessively than normal :)

    There is now a setting called 'Normal Source' on all Alloy materials that allows you to kill normal mapping (along with a bunch of other computation that occurs as a result of it), by setting it to 'vertex normals'. This is especially useful for non-directional light-mapped surfaces, distant objects, billboards, etc. Basically, if you don't _need_ a bumpy look out of a material, you can now turn a whole bunch of that off now, as well as save yourself a texture sample.

    A number of shaders have been condensed from being separate to being a single shader type with more options. This has been done for the sake of modularity&organization (as Alloy's codebase is already pretty massive). The new Vertex Blend shader can now be used either with 3 or 4 splats, and if you're looking for a cheap option that maximizes ground variation on a mesh for VR games, I highly recommend it (as I'm using it in H3VR).

    Beyond that, a 'Wetness' feature has been added as an option for pretty much all shader now, allowing you mask via vcolors or texture mask, to darken/smoothen materials. We have some longer term plans to eventually play around with weather, but for now this should cover 90-some percent of cases where one needs to get things looking soaked.

    Lastly, and MOST importantly: Upgrading to this version REQUIRES running our material migrator after import. Due to adding the flag to remove normal maps, they will be turned off/messed up on your existing materials. Follow the instructions on the popup though, and the migrator should fix the problem project-wide for you. You should only have to do this once per project (and not at all if you're making brand new projects with 3.4.3 and forward). Let us know if anything goes awry.

    Cheers!

    Changelog:
    Version 3.4.3
    =====================
    Scripts:
    - Changed "Material Migrator" to run on the entire project, rather than per-scene.
    - Changed "Material Migrator" to fix Normals Source on existing materials.
    - Changed "Keyword Report" to "Material Report".
    - Changed "Material Report" to add a section for shaders to list their associated materials.
    - Changed "Light Migrator" to "Light Converter".
    - Fixed "Light Converter" to properly convert the intensity from Unity lights.

    Shaders:
    - Added config options to set which data is read from which channels in the packed maps.
    - Added a "Normals Source" setting to enable/disable normal maps.
    * Setting it to "Vertex Normals" enables extensive optimizations to greatly reduce a material's cost.
    - Added "Vertex Blend" shader with an optional Alpha splat, and toggleable TriPlanar mapping.
    * Add Alpha splat, and set Roughness Source to Base Color Alpha to match the old "Vertex Blend 4Splat" shader.
    - Added "SpeedTree (Forward)" shader that is forward-only and supports the full set of Transmission parameters.
    - Changed "Skin*" shaders to add Parallax feature.
    - Changed "Skin*" shaders and camera components to restore Bias and Scale inputs.
    - Changed "Terrain" shaders to support enabling optimizations when no normal maps are used.
    - Changed "Vertex Blend" to add AO2, Decal support.
    - Changed "Terrain" shaders to support TriPlanar mapping as a toggleable feature.
    - Changed "Roughness Source" to be global for the whole shader, and eliminated it in Secondary and Oriented Textures sections.
    - Fixed "TriPlanar" and "Oriented" shaders to correctly map textures for shadows and lightmap baking.
    - Fixed "Terrain/4Splat" fog in forward mode.
    - Renamed "TriPlanar/Full" to "TriPlanar" and modified it to encompass the "TriPlanar/Lite" inputs.

    Features:
    - Added "Wetness" feature to most of the shaders.
    - Changed "Detail" to add a "Mask Strength" parameter.

    Legacy:
    - Moved "Terrain * TriPlanar" shaders into this set.
    - Moved "TriPlanar/Lite" shaders into this set.
    - Moved "Vertex Blend/4Splat *" shaders into this set.

    Mods:
    - Removed "Wetmask/Core" & "Wetmask/Weighted Blend".

    Integration:
    - Added support for "Hx Volumetric Lighting" transparency integration.
    - Fixed Substance Painter custom shader to not cause rough specular in shadowed areas.
    - Updated Substance Painter custom shader to support version 2.2.
     
  15. Deleted User

    Deleted User

    Guest

    @Elecman
    Why not just use the Glass shader?
     
  16. Crossway

    Crossway

    Joined:
    May 24, 2016
    Posts:
    507
    I recorded a video to show my problem with Alloy but no one didn't even answer me :confused:
     
  17. Deleted User

    Deleted User

    Guest

    @Crossway
    Which problem and which video? I don't see any videos from you in the prior 3-4 pages.
     
  18. Crossway

    Crossway

    Joined:
    May 24, 2016
    Posts:
    507
    Video is on the current page! (Crossway,Thursday at 2:15 AM)

     
  19. Deleted User

    Deleted User

    Guest

    @Crossway
    Apparently the forums failed to send me updates over the past few days. :/

    Okay, what you are seeing is the result of our BRDF having the correct intensity for specular highlights vs Unity's BRDF, and ours having support for area lights. Does your Directional Light have an area light component on it?

    @istavang
    Because the Unity betas have been very crashy as well as making lots of changes between point releases that break our code. We also prefer to avoid splitting our code base while trying to support both current and beta users. So it has become our policy to wait for the betas to reach b8-b10 before making the switch.
     
    chiapet1021 likes this.
  20. Elecman

    Elecman

    Joined:
    May 5, 2011
    Posts:
    1,371
    Oh, I figured the core shader would be more fast but I guess as long as I don't use hundreds of glass materials no one would notice a frame rate difference. Will use glass.
     
  21. Deleted User

    Deleted User

    Guest

    @Elecman
    Also use the "Glass/LowQuality" shader so that it will use a shared screen grab rather than regenerating it per object.
     
  22. Crossway

    Crossway

    Joined:
    May 24, 2016
    Posts:
    507
    There is no area light component on my directional light, when roughness sets on 0, there shouldn't be any specular highlight.
     
  23. StaffanEk

    StaffanEk

    Joined:
    Jul 13, 2012
    Posts:
    380
    It would be great if a shader could use an inverted baked reflection probe for transparency. It would probably be cheaper. You could invert a reflection cubemap manually of course but you would still need real reflections on your glass.
     
  24. Deleted User

    Deleted User

    Guest

    @Crossway
    Alloy's AreaLight component is mandatory for all dynamic light types, including Directional Lights since they can be Disc light sources. Please use the Light Converter tool to update your lights for each of your scenes.

    Roughness doesn't completely kill specular highlights. Real world materials, no matter how rough they are, always exhibit some kind of specular response at grazing angles.
     
  25. Deschanna

    Deschanna

    Joined:
    Jul 4, 2016
    Posts:
    6
    First off, I am a total beginner with all of this so pardon me if I ask something totally apparent. I tried to google but didn't get anything out of it. I have Alloy in my project, very recently bought, and I already see it's making wonders. But I have a problem with using Human > Hair > ... (High Quality Two Sided, but it's the same with other options)

    The character's hair renders just peachy when his head is against something on the background (mountains, terrain, trees etc.) but if I rotate the camera so that his head is against the skybox (the basic skybox that comes with a basic camera added to the scene) then a part of his hair becomes transparent and returns to normal only when I rotate the camera so that the skybox is no longer touching his head/hair. I am using forward rendering, deferred doesn't change it.

    I don't have this problem with Unity's standard shader, but I don't want to use it when I've seen what Alloy can do.

    What's going on here, you guys familiar with this?

    Thank you so much!
     
  26. Deleted User

    Deleted User

    Guest

    @Deschanna
    Unfortunately that's a known and ongoing problem based on when the material is rendered. Right now, it renders in the alpha test part of the pipeline to make it work with post-effects. Sadly that means it breaks for layered transparency and skyboxes. If we switched it to work during the transparency pass, then it would have the opposite problem.

    As a short term solution, I will likely just have to do a release that has both variants as options. >_<
     
  27. Crossway

    Crossway

    Joined:
    May 24, 2016
    Posts:
    507
    I really love Alloy It's a whole shader package. just there an issue I have with it and other shader packages (more with alloy).
    I have totally white specular area on my objects, is there anyway to make specular high lighte darker?
     
  28. Deleted User

    Deleted User

    Guest

    @Crossway
    The easiest way to reduce the specular intensity is to increase the size of your area lights. The reason it is so bright is that by default the lights are infinitely small points. By increasing their size even a little, the specular intensity goes WAY down as the energy is spread over a wider area. It also results in a much nicer looking highlight.
     
    Crossway likes this.
  29. Crossway

    Crossway

    Joined:
    May 24, 2016
    Posts:
    507
    I mean was its color. For example can I change specular highlight color to red or green? for making a material darker I can change its vertex color so if that was possible for specular highlight too that would be cool.
     
  30. Deleted User

    Deleted User

    Guest

    @Crossway
    No, we do not have the ability to change the specular highlight color. The most we could manage was being able to disable the highlight entirely.
     
    Crossway likes this.
  31. davidjfranco

    davidjfranco

    Joined:
    Oct 9, 2014
    Posts:
    23
    Hi Alloy folks... loving Alloy. Just wondering what your estimated update time is for a workable version with 5.5? :)
     
    Crossway likes this.
  32. Crossway

    Crossway

    Joined:
    May 24, 2016
    Posts:
    507
    Thanks, about Alloy area light I mentioned it doesn't work with Time of Day or Azure sky! it works on a directional light but when I place it on Time of Day sun light it doesn't work at all (same with azure).
     
  33. Deleted User

    Deleted User

    Guest

    @davidjfranco
    I will try to look into it this weekend, and see if the changes are small enough to put out a patch. No guarantees though.

    @Crossway
    Some of our other customers have encountered that problem, and had to patch the assets with a call to our custom Area Light properties. I'm going to be investigating a, hopefully, simpler solution in the coming week.
     
    Crossway likes this.
  34. davidjfranco

    davidjfranco

    Joined:
    Oct 9, 2014
    Posts:
    23
    That'd be wonderful. Thanks for your fast response.
     
  35. Crossway

    Crossway

    Joined:
    May 24, 2016
    Posts:
    507
    This is the error I get on Unity 5.5.0 b3. is there any temporary fix for this?

    Shader error in 'Alloy/Car Paint': invalid subscript 'boxMin' at Assets/Alloy/Shaders/Framework/Pass.cginc(312) (on d3d11)

    Compiling Vertex program with DIRECTIONAL SHADOWS_SCREEN EFFECT_BUMP
    Platform defines: UNITY_ENABLE_REFLECTION_BUFFERS UNITY_PBS_USE_BRDF1 UNITY_SPECCUBE_BOX_PROJECTION UNITY_SPECCUBE_BLENDING SHADER_API_DESKTOP
     
  36. Elecman

    Elecman

    Joined:
    May 5, 2011
    Posts:
    1,371
    Is there a script available which automatically creates Alloy packed maps? I don't fancy the manual work of almost 1000 textures, especially when dealing with substances.
     
  37. istavang

    istavang

    Joined:
    Jan 17, 2015
    Posts:
    19
    can any alloy shaders be used on Andriod platform for shield tablet Tegra K1 geforce kepler (openGLES 3 ) ??

    Looking forward to any feedback

    Thanks
    Dan
     
  38. Deleted User

    Deleted User

    Guest

    @Crossway
    We've not yet looked into what needs to be done to support the Unity 5.5 beta. I will try to look into it this weekend.

    @Elecman
    Unfortunately no.

    @istavang
    In the past we've managed to get a customized version of Alloy to run on the prototype hardware for a demo, but haven't tested it since then. The major limiting factor right now would be the lack of essential features being supported by Unity on the hardware such as Linear-space HDR rendering.
     
    Crossway likes this.
  39. Deleted User

    Deleted User

    Guest

    @Crossway @istavang @davidjfranco
    Okay, having had a chance to look it over it would appear that updating Alloy to Unity 5.5 is going to require extensive modifications. As such, I can't provide any easy workarounds at this time.
     
  40. TechnicalArtist

    TechnicalArtist

    Joined:
    Jul 9, 2012
    Posts:
    736
    Hi,

    Any comment on VULKAN RENDERER ?

    In feature alloy work with VULKAN RENDERER ?
     
  41. xenius

    xenius

    Joined:
    Sep 30, 2010
    Posts:
    523
    its a preview of a renderer. In nowhere in the announcement did Unity mention that they'd be extending it to support any features their current ogles3 doesn't.
     
  42. TechnicalArtist

    TechnicalArtist

    Joined:
    Jul 9, 2012
    Posts:
    736
    Thanks for reply.
     
  43. davidjfranco

    davidjfranco

    Joined:
    Oct 9, 2014
    Posts:
    23
    thanks for the update!
     
  44. istavang

    istavang

    Joined:
    Jan 17, 2015
    Posts:
    19
    **********************************************WHAT *******************************************
    Are you kidding me ?? this is not a game , we work here ,can u please tell me how I shall get it to work when I trusted your pro plugin , ur plugin is the only plugin thats behind at all time , we cant babysit alloy each time we need to upgrade for other needs , your QA is not up to date at all , I talked to unity and they say u have accsess to alfa at all time , so it shoudnt be neserecry to stay behind , u have a responsebilty when u sell a pro shader framework that we pro depents up on , or your rating will sertenly go down , ask unity for help if nessesery , we cant have this lackness any longer .

    Please take reponsebilety to deliver quality in every aspect of the product

    , I have converted my main project to 5.5.due to a needed future , and it is not backward compatible , so I must have solution fast.

    Looking forward to your posetive and quick fix

    Thanks Dan
     
  45. AcidArrow

    AcidArrow

    Joined:
    May 20, 2010
    Posts:
    11,717
    Why are you on a beta then?
     
    KWaldt, moure, chiapet1021 and 5 others like this.
  46. xenius

    xenius

    Joined:
    Sep 30, 2010
    Posts:
    523
    @istavang: _Excuse me_, not having a version of an asset ready for a _beta_ version of Unity is not being 'behind'. We develop Alloy for the _current_ version of Unity, and typically have the next version ready for testing when whichever is the next version of Unity hits release candidate.

    Unity makes _large_ changes per point release related to their lighting headers, enlighten, and other systems we plug into, such that to maintain active versions of Alloy for both the current, and running beta is far too labor intensive for a framework of its complexity. This is not a matter of not knowing what to do (ie. we don't 'need help' from Unity on this matter), its a matter of doing the work at a sustainable pace.

    Further, the Unity betas have been a _shitshow_ from a stability/usability standpoint until close to Release Candidate. I will not waste _our_ time developing on unstable software. If you chose to do so, that is your prerogative, but don't come into our thread, tantruming, because we haven't prepared a version of Alloy for a beta version of Unity that has _barely_ been out a month. If you have upgraded your project (without backing it up??), that is your mistake.

    Alloy for U5.5 will be available some time towards the end of the 5.5 beta cycle.
     
  47. Deleted User

    Deleted User

    Guest

    Alloy 3.4.4 for Unity 5.4+ is live on the Store

    This is a small point release to address a build issue and add support for using Unity's Animation Clips with Alloy's Area Lights. To use them, simply do the following:
    1. At the start of the clip, enable the new "Animated by Clip" toggle on the AreaLight component.
    2. Modify the Alloy "Color" and "Intensity" properties.
      • Automatic when using editor recording.
      • Doesn't work with Unity's provided "light.color" and "light.intensity" options.
    3. At the end of the clip, disable the "Animated by Clip" toggle.
    Please try it out and let me know what you think. Cheers!

    Changelog:
    Version 3.4.4
    =====================
    Scripts:
    - Added "Animated by Clip" toggle to the AreaLight component to support Animation Clips.
    - Fixed issue where "AlloyRequiredActions.cs" was causing build errors.
     
    xenius and punk like this.
  48. asemenov

    asemenov

    Joined:
    Jan 13, 2014
    Posts:
    11
    Hi! I have the following problem with Alloy: for some reason objects with Material that uses Shader Alloy/Core not batching. nor dynamic nor static. The same objects with Unity Standard shader are batching.
    Test scene is extremely primitive:
    Main Camera
    Directional light
    Cylinder1
    Cylinder2 (Both same mesh, same material)

    I am on Unity 5.4.1f DX11, Alloy 3.4.4.
    Unity is batching implicitly, any ideas what causes the problem?
     
  49. Aabel

    Aabel

    Joined:
    Nov 4, 2012
    Posts:
    193
    Is there any chance of getting a cut-out mode for the skin shader so it can be used with the morph 3d character system?
     
  50. MirageVRUnity

    MirageVRUnity

    Joined:
    May 10, 2016
    Posts:
    16
    I was wondering, do you guys offer training or scene consultations with using Alloy?