Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Help  [Resolved] (Android/Unity) The Obi Fluid Renderer kill the performance.
#3
Just adding the Write Depth on the simple shader ... doesn't work on the android. The particles have no rendering.

Code:
Shader "Toto/Fluid/Simple3DFluid"
{
    Properties
    {
        _MainTex ("Texture", 2D) = "white" {}
        _RefractionCoeff ("Refraction", Range (-0.1, 0.1)) = 0.01
        _Color ("Fluid color", Color) = (0.3,0.6,1,1)
    }

    SubShader
   {
        Cull Back
        ZWrite On
        ZTest LEqual

       Pass
       {
           Name "Simple3DFluid"
           Tags {"LightMode" = "ForwardBase"}
            Offset 1, 1

           Blend SrcAlpha OneMinusSrcAlpha

           CGPROGRAM
           #pragma vertex vert
           #pragma fragment frag
           //#pragma target 3.0

            #include "../Obi/Resources/ObiMaterials/ObiParticles.cginc"

...


Code:
Shader "Toto/Simple 3D Particles" {

Properties {
    _Color         ("Particle color", Color) = (1,1,1,1)
}

    SubShader
    {
        Cull Back
        ZWrite On
        ZTest LEqual

        Pass
        {
            Name "ParticleFwdBase"
            Tags {"Queue"="Geometry" "IgnoreProjector"="True" "RenderType"="Opaque" "LightMode" = "ForwardBase"}
            Blend SrcAlpha OneMinusSrcAlpha  

            CGPROGRAM
            #pragma vertex vert
            #pragma fragment frag
            #pragma fragmentoption ARB_precision_hint_fastest

            #pragma multi_compile_fwdbase nolightmap

            #include "../Obi/Resources/ObiMaterials/ObiParticles.cginc"
Reply


Messages In This Thread
RE: [Android][Unity] The Obi Fluid Renderer kill the performance. - by Suryavarman - 28-06-2019, 11:16 AM