Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] The double buffered option for shaderNode is incorrect #65

Open
o2co2 opened this issue Oct 23, 2023 · 1 comment
Open

[BUG] The double buffered option for shaderNode is incorrect #65

o2co2 opened this issue Oct 23, 2023 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@o2co2
Copy link

o2co2 commented Oct 23, 2023

What happened?
The double buffered option for shaderNode is incorrect

To Reproduce
Steps to reproduce the behavior:
image

Setup:

  • OS: [e.g. Windows]
  • Unity Version: [e.g. 2023.1.7]
  • Mixture Version [0.4.2]

Additional informations
Add any other context about the problem here.

@o2co2 o2co2 added the bug Something isn't working label Oct 23, 2023
@o2co2
Copy link
Author

o2co2 commented Oct 24, 2023

        if (settings.doubleBuffered)
        {
             CustomRenderTextureUpdateZone[] updateZones;

            switch (output.dimension)
            {
                default:
                case TextureDimension.Cube: 
                    throw new NotImplementedException();
                case TextureDimension.Tex2D:
                    updateZones = new CustomRenderTextureUpdateZone[]
                    {
                        new CustomRenderTextureUpdateZone
                        {
                            needSwap = true,
                            passIndex = 0,
                            rotation = 0f, 
                            updateZoneCenter = new Vector3(0.5f, 0.5f, 0.5f),
                            updateZoneSize = new Vector3(1f, 1f, 1f),
                        },
                        
                    };
                    break;
                case TextureDimension.Tex3D:
                    throw new NotImplementedException();
                    break;
            }
            
            settings.doubleBuffered = true;

            // Setup the successive passes needed or the blur
            output.SetUpdateZones(updateZones);
        }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants