Obi Official Forum

Full Version: Fluid is lost when running on iPhone
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi, the scenes worked well in editor, but when I built it for iOS project, and run it on iPhone, all the fluid was lost.  Any help? Thanks.


Using obi fluid 3.4 , Unity 2017.3.1, iOS 11.3.1


Here are the logs from xcode:
Code:
2018-06-15 16:50:08.228383+0800 test[18079:7033551] [DYMTLInitPlatform] platform initialization successful
2018-06-15 16:50:08.273832+0800 test[18079:7033417] -> registered mono modules 0x105e55590
2018-06-15 16:50:08.450612+0800 test[18079:7033417] [Accessibility] ****************** Loading GAX Client Bundle ****************
-> applicationDidFinishLaunching()
2018-06-15 16:50:08.665330+0800 test[18079:7033417] Metal GPU Frame Capture Enabled
2018-06-15 16:50:08.666675+0800 test[18079:7033417] Metal API Validation Disabled
-> applicationDidBecomeActive()
Renderer: Apple A11 GPU
Vendor:   Apple Inc.
Version:  OpenGL ES 2.0 Metal - 52.3.2
GLES:     2
GL_OES_depth_texture GL_OES_depth_texture_cube_map GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_texture_float GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_vertex_array_object GL_EXT_blend_minmax GL_EXT_color_buffer_half_float GL_EXT_debug_label GL_EXT_debug_marker GL_EXT_discard_framebuffer GL_EXT_draw_instanced GL_EXT_instanced_arrays GL_EXT_map_buffer_range GL_EXT_occlusion_query_boolean GL_EXT_pvrtc_sRGB GL_EXT_read_format_bgra GL_EXT_separate_shader_objects GL_EXT_shader_framebuffer_fetch GL_EXT_shader_texture_lod GL_EXT_shadow_samplers GL_EXT_sRGB GL_EXT_texture_filter_anisotropic GL_EXT_texture_rg GL_EXT_texture_storage GL_APPLE_clip_distance GL_APPLE_color_buffer_packed_float GL_APPLE_copy_texture_levels GL_APPLE_framebuffer_multisample GL_APPLE_rgb_422 GL_APPLE_sync GL_APPLE_texture_format_BGRA8888 GL_APPLE_texture_max_level GL_APPLE_texture_packed_float GL_IMG_r
ead_format GL_IMG_texture_compression_pvrtc
OPENGL LOG: Creating OpenGL ES 2.0 graphics device ; Context level  <OpenGL ES 2.0> ; Context handle -738010944
Initialize engine version: 2017.3.1f1 (fc1d3344e6ea)
WARNING: 0:4: extension 'GL_EXT_frag_depth' is not supported
ERROR: 0:38: Use of undeclared identifier 'gl_FragDepthEXT'

Note: Creation of internal variant of shader 'Hidden/Internal-MotionVectors' failed.
WARNING: Shader Unsupported: 'Hidden/Internal-MotionVectors' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/Internal-MotionVectors' - Setting to default shader.
WARNING: Shader Unsupported: 'Hidden/BlitToDepth' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/BlitToDepth' - Setting to default shader.
WARNING: Shader Unsupported: 'Hidden/BlitToDepth_MSAA' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/BlitToDepth_MSAA' - Setting to default shader.
WARNING: 0:4: extension 'GL_EXT_frag_depth' is not supported
ERROR: 0:14: Use of undeclared identifier 'gl_FragDepthEXT'

Note: Creation of internal variant of shader 'Hidden/BlitCopyWithDepth' failed.
WARNING: Shader Unsupported: 'Hidden/BlitCopyWithDepth' - Pass '' has no vertex shader
WARNING: Shader Unsupported: 'Hidden/BlitCopyWithDepth' - Setting to default shader.
WARNING: Shader Unsupported: 'Obi/Particles' - Pass 'PARTICLEFWDBASE' has no vertex shader
WARNING: Shader Unsupported: 'Obi/Particles' - Pass 'SHADOWCASTER' has no vertex shader
WARNING: Shader Unsupported: 'Obi/Particles' - All passes removed
WARNING: 0:6: extension 'GL_EXT_frag_depth' is not supported
WARNING: 0:79: Overflow in implicit constant conversion, minimum range for lowp float is (-2,2)
ERROR: 0:213: Use of undeclared identifier 'gl_FragDepthEXT'

Note: Creation of internal variant of shader 'Obi/Fluid/DielectricFluid' failed.
WARNING: Shader Unsupported: 'Obi/Fluid/DielectricFluid' - Pass 'DIELECTRICFLUID' has no vertex shader
WARNING: Shader Unsupported: 'Obi/Fluid/DielectricFluid' - All passes removed
ERROR: Shader Shader is not supported on this GPU (none of subshaders/fallbacks are suitable)WARNING: Shader Unsupported: 'Obi/Fluid/DielectricFluid' - Setting to default shader.
WARNING: Shader Unsupported: 'Obi/Fluid/Colors/FluidColorsBlend' - Pass 'FLUIDCOLORS' has no vertex shader
Setting up 1 worker threads for Enlighten.
 Thread -> id: 16c3f7000 -> priority: 1
UnloadTime: 5.650791 ms
WARNING: Shader Unsupported: 'Hidden/FluidThickness' - Pass 'FLUIDTHICKNESS' has no vertex shader
Obi Fluid Renderer not supported in this platform.
Obi.ObiFluidRenderer:Setup()
Obi.ObiBaseFluidRenderer:OnPreRender()

(Filename: /Users/builduser/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)

ArgumentNullException: Argument cannot be null.
Parameter name: material
 at UnityEngine.Rendering.CommandBuffer.Internal_DrawMesh (UnityEngine.Mesh mesh, Matrix4x4 matrix, UnityEngine.Material material, Int32 submeshIndex, Int32 shaderPass, UnityEngine.MaterialPropertyBlock properties) [0x00000] in <filename unknown>:0
 at UnityEngine.Rendering.CommandBuffer.DrawMesh (UnityEngine.Mesh mesh, Matrix4x4 matrix, UnityEngine.Material material, Int32 submeshIndex, Int32 shaderPass) [0x00000] in <filename unknown>:0
 at Obi.ObiFluidRenderer.UpdateFluidRenderingCommandBuffer () [0x00000] in <filename unknown>:0
 at Obi.ObiBaseFluidRenderer.OnPreRender () [0x00000] in <filename unknown>:0

(Filename: currently not available on il2cpp Line: -1)

There is an error saying material cannot be null, but I could not figure out how to fix it.
Hi there,

This bit:

(15-06-2018, 09:56 AM)cowill Wrote: [ -> ]ERROR: Shader Shader is not supported on this GPU (none of subshaders/fallbacks are suitable)WARNING: Shader Unsupported: 'Obi/Fluid/DielectricFluid' - Setting to default shader.
WARNING: Shader Unsupported: 'Obi/Fluid/Colors/FluidColorsBlend' - Pass 'FLUIDCOLORS' has no vertex shader
Setting up 1 worker threads for Enlighten.
 Thread -> id: 16c3f7000 -> priority: 1
UnloadTime: 5.650791 ms
WARNING: Shader Unsupported: 'Hidden/FluidThickness' - Pass 'FLUIDTHICKNESS' has no vertex shader
Obi Fluid Renderer not supported in this platform.

means the standard fluid shader is not compatible with your iPhone. This results in the fluid material being null. Simply use the SimpleFluidRenderer instead, which is optimized for mobile. See:

http://obi.virtualmethodstudio.com/tutor...ering.html
(15-06-2018, 12:18 PM)josemendez Wrote: [ -> ]Hi there,

This bit:


means the standard fluid shader is not compatible with your iPhone. This results in the fluid material being null. Simply use the SimpleFluidRenderer instead, which is optimized for mobile. See:

http://obi.virtualmethodstudio.com/tutor...ering.html

Thanks for your reply. It seems that the SimpleFluidRenderer only support 2D fluid, right?  Are there other solutions can support 3D fluid on my iPhones? Here is my device list: iPhone X , iPhone 6, iPhone 6s. None of them work. Triste