Skip to content
This repository has been archived by the owner on Sep 14, 2021. It is now read-only.

Lightweight Render Pipeline (LWRP) AR background stays black #131

Open
gitunit opened this issue Mar 3, 2018 · 8 comments
Open

Lightweight Render Pipeline (LWRP) AR background stays black #131

gitunit opened this issue Mar 3, 2018 · 8 comments

Comments

@gitunit
Copy link

gitunit commented Mar 3, 2018

in unity 2018.1b one can use the lightweight render pipeline. i was able to port the background shader, however it stayed black and only feature points were visualized. would be awesome if we had a working background shader that is compatible with the lightweight render pipeline.

@pablisho
Copy link
Contributor

pablisho commented Mar 5, 2018

Thanks for the feature request. We'll be looking into 2018.1 support for next releases.

@iBicha
Copy link

iBicha commented Mar 6, 2018

@gitunit There is a quick way to support the lightweight render pipeline.
These changes works for me.
In LightweightPipeline.cs#L513 replace

if (m_CurrCamera.clearFlags == CameraClearFlags.Skybox)
    context.DrawSkybox(m_CurrCamera);

with

if (m_CurrCamera.clearFlags == CameraClearFlags.Skybox)
    context.DrawSkybox(m_CurrCamera);
else if (m_CurrCamera.clearFlags == CameraClearFlags.Depth && m_CurrCamera.commandBufferCount > 0)
{
    var commands = m_CurrCamera.GetCommandBuffers(CameraEvent.BeforeForwardOpaque);
    foreach (var cmd in commands)
    {
        context.ExecuteCommandBuffer(cmd);
    }
}

Let me know if this works for you.

Edit: for deferred rendering path, the event would be CameraEvent.BeforeGBuffer, so maybe check commands with both events.

@gitunit
Copy link
Author

gitunit commented Mar 11, 2018

@iBicha it works. thx for the quick fix. edit: though now all foreground objects are transparent.

@fredsa fredsa changed the title lightweight render pipeline arbackground stays black Lightweight Render Pipeline (LWRP) AR background stays black Mar 1, 2019
@ice-github
Copy link

ice-github commented May 9, 2019

In LightweightPipeline.cs#L513 replace

the link isn't available now.
Does anyone know the revision of the code?

@FejZa
Copy link

FejZa commented May 18, 2019

Any news on this?

@gakabes
Copy link

gakabes commented Jun 16, 2019

Any update on this? I switched from ARFoundation to ARCore for augmented images, but the lack of LWRP support is a bummer.

@michaelybecker
Copy link

michaelybecker commented Jun 20, 2019

+1.
I know Unity wants to funnel handheld mobile devs towards ARFoundation but ARCore currently has far superior remoting tools and having a clear pathway to using it w/LWRP would be extremely helpful.

@uffeflarup
Copy link

Same question here: Is there any news on supporting LWRP when using ARCore?

Thanks a lot in advance.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

8 participants