Question about LWRP in 5.0 - Printable Version +- Obi Official Forum (https://obi.virtualmethodstudio.com/forum) +-- Forum: Obi Users Category (https://obi.virtualmethodstudio.com/forum/forum-1.html) +--- Forum: Obi Fluid (https://obi.virtualmethodstudio.com/forum/forum-3.html) +--- Thread: Question about LWRP in 5.0 (/thread-1490.html) Pages:
1
2
|
Question about LWRP in 5.0 - TheDopple - 21-11-2019 Hello, recent Obi Fluid user here! Now that 5.0 is out, with "Experimental LWRP Support", How would I actually test this feature? I'm using Unity version 2019.3.0b11 with the Universal Render Pipeline (Which should work the same as LWRP), this is a blank project with the Fluid Package I have the fluid rendererer feature attached to my Pipeline asset, but the fluid still won't render (But I can get the particle renderer to work) Is there something I'm missing, or is the update not yet compatible with URP? [attachment=480] RE: Question about LWRP in 5.0 - josemendez - 21-11-2019 (21-11-2019, 05:06 PM)TheDopple Wrote: Hello, recent Obi Fluid user here! Still documenting it! Sorry :S. There's ObiFluidRendererFeature.cs, which is a scriptable renderer feature for LWRP. By creating a custom forward renderer and adding this feature, fluids will be rendered in LWRP. Have yet to check for compatibility with URP, that's in part why it's still experimental. (things change and get deprecated so freaking fast from Unity's side... is hard to keep up. We were still working in LWRP support when they announced it was getting replaced by the identical-but-not-quite URP). Let me know if you need help setting it up! RE: Question about LWRP in 5.0 - TheDopple - 21-11-2019 (21-11-2019, 07:33 PM)josemendez Wrote: Still documenting it! Sorry :S. I already tried creating a custom FR and gave it the ObiFluidRendereFeature, but still nothing. I'm pretty sure it might work in LWRP, but my current project involves URP, and it does not seem to work currently. RE: Question about LWRP in 5.0 - josemendez - 22-11-2019 (21-11-2019, 09:22 PM)TheDopple Wrote: I already tried creating a custom FR and gave it the ObiFluidRendereFeature, but still nothing. Hi, Did you provide both a color and a fluid material, like in the regular FluidRenderer? FluidColorBlend (color material) and DielectricFluid (fluid material) work well. Will beging testing URP asap. RE: Question about LWRP in 5.0 - TheDopple - 22-11-2019 (22-11-2019, 11:19 AM)josemendez Wrote: Hi, As you can see in my screeenshot that I posted with the OP, I did indeed provide the color and fluid materials for the feature, I even used FluidColorBlend and DielectricFluid RE: Question about LWRP in 5.0 - TheFlyHawk - 23-11-2019 Unity version 2019.2.11 [attachment=481] RE: Question about LWRP in 5.0 - darbycostello - 23-11-2019 (23-11-2019, 03:13 AM)TheFlyHawk Wrote: Unity version 2019.2.11 Exactly the same issue here. However, I was able to attach the rendering feature by editing the ObiFluidRendererFeature.cs file. Specifically, I commented the compiler directive #if UNITY_2019_2_OR_NEWER && SRP_LIGHTWEIGHT from the top of the script along with the #endif at the bottom. Looks like it was causing some kind of conflict. RE: Question about LWRP in 5.0 - josemendez - 23-11-2019 (23-11-2019, 04:34 PM)darbycostello Wrote: Exactly the same issue here. However, I was able to attach the rendering feature by editing the ObiFluidRendererFeature.cs file. SRP_LIGHTWEIGHT is a version define, created by the /Obi/Scripts/Obi.asmdef assembly definition file if com.unity.render-pipelines.lightweight version 6.0 or higher is present in the project. (You can check this yourself by selecting the Obi.asmdef file found in /Obi/Scripts/, and looking at the version defines section in the inspector). So as long as you're using Unity 2019.2 or higher and LWRP 6.0 or higher, both precompiler constants should be defined, and the renderer feature should compile without issue. Maybe your LWRP package is a lower version than 6.0? (or Unity got confused due to some other reason?) RE: Question about LWRP in 5.0 - darbycostello - 23-11-2019 (23-11-2019, 08:28 PM)josemendez Wrote: SRP_LIGHTWEIGHT is a version define, created by the /Obi/Scripts/Obi.asmdef assembly definition file if com.unity.render-pipelines.lightweight version 6.0 or higher is present in the project. (You can check this yourself by selecting the Obi.asmdef file found in /Obi/Scripts/, and looking at the version defines section in the inspector). Thanks for the response. LWRP is version 6.9. However this was part of an upgrade of an existing project to LWRP. One that had used Obi Fluid 4 (replaced with v5), so it's possible the compiler got confused in some other way. I tried it with a fresh LWRP project in Unity 2019.2.13 and didn't get any errors, so all is well. I just pulled up the fluid mill example, set up the LWRP with a custom forward renderer, dropped in the Obi renderer feature and it works beautifully, as below. Really great work getting this to work with the LWRP RE: Question about LWRP in 5.0 - josemendez - 23-11-2019 Glad you're happy with the result! For the OP: rest assured I will check for compatibility with URP during next week and carry out any adjustments needed to ensure compatibility with URP as well. |