Jump to: Board index » General » Fusion

Why does Particles add transparency?

Learn about 3D compositing, animation, broadcast design and VFX workflows.
  • Author
  • Message
Offline

Jinxer

  • Posts: 41
  • Joined: Thu Sep 23, 2021 3:06 pm
  • Real Name: Sergey Zinchenko

Why does Particles add transparency?

PostFri Dec 03, 2021 1:04 am

It looks as expected (squares without alpha channel) after the pRender node. But the Renderer3D node adds transparency. Can I control this alpha level?
Image
Online
User avatar

Bryan Ray

  • Posts: 2075
  • Joined: Mon Nov 28, 2016 5:32 am
  • Location: Los Angeles, CA, USA

Re: Why does Particles add transparency?

PostFri Dec 03, 2021 1:34 am

That looks like you're probably rendering too small, and antialiasing is mixing your particles with the empty space around them.

But it's impossible to know for sure without more information. Post the nodes rather than a screenshot, and perhaps we can be of more help. Copy the nodes, then paste them here between [code] [/code] tags.
Bryan Ray
http://www.bryanray.name
http://www.musevfx.com
Offline

Jinxer

  • Posts: 41
  • Joined: Thu Sep 23, 2021 3:06 pm
  • Real Name: Sergey Zinchenko

Re: Why does Particles add transparency?

PostFri Dec 03, 2021 1:47 am

Bryan Ray wrote:Post the nodes

You are right, the image is small.
Code: Select all
{
   Tools = ordered() {
      Background3 = Background {
         Inputs = {
            GlobalOut = Input { Value = 274, },
            Width = Input { Value = 192, },
            Height = Input { Value = 256, },
            ["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
            TopLeftRed = Input { Value = 0.26, },
            TopLeftGreen = Input { Value = 0.409, },
            TopLeftBlue = Input { Value = 0.622, },
            EffectMask = Input {
               SourceOp = "Ellipse1",
               Source = "Mask",
            }
         },
         ViewInfo = OperatorInfo { Pos = { -55, 379.5 } },
      },
      Ellipse1 = EllipseMask {
         Inputs = {
            Filter = Input { Value = FuID { "Fast Gaussian" }, },
            MaskWidth = Input { Value = 1920, },
            MaskHeight = Input { Value = 1080, },
            PixelAspect = Input { Value = { 1, 1 }, },
            UseFrameFormatSettings = Input { Value = 1, },
            ClippingMode = Input { Value = FuID { "None" }, },
         },
         ViewInfo = OperatorInfo { Pos = { -55, 346.5 } },
      },
      pImageEmitter1_1 = pImageEmitter {
         ID = 237,
         CustomData = { Path = { Map = { ["Setting:"] = "Templates:\\MyTemplates\\" } }, },
         Inputs = {
            ["ParticleStyleBrush.Brush"] = Input {
               Value = 47,
               UserString1 = "star_7sides",
            },
            XDensity = Input { Value = 0.332, },
            YDensity = Input {
               Value = 0.332,
               Expression = "XDensity",
            },
            AlphaThreshold = Input { Value = 0.004, },
            Lifespan = Input {
               Value = 275,
               Expression = "comp.RenderEnd+1",
            },
            PivotNest = Input { Value = 1, },
            VelocityControls = Input { Value = 1, },
            Input = Input {
               SourceOp = "Background3",
               Source = "Output",
            },
            Style = Input { Value = FuID { "ParticleStyleNGon" }, },
            ["ParticleStyleNGon.NGonType"] = Input { Value = 2, },
            ["ParticleStyleNGon.NGonSides"] = Input { Value = 4, },
            ["ParticleStyleNGon.NGonStarryness"] = Input { Value = 0, },
            ["ParticleStyle.SizeControls"] = Input { Value = 1, },
            ["ParticleStyle.Size"] = Input { Value = 0.013, },
            ["ParticleStyle.SizeOverLife"] = Input {
               SourceOp = "pImageEmitter1SizeOverLife_1",
               Source = "Value",
            },
            ["ParticleStyle.MergeControls"] = Input { Value = 1, },
            ["ParticleStyle.BlurOverLife"] = Input {
               SourceOp = "pImageEmitter1BlurOverLife2D_1",
               Source = "Value",
            },
         },
         ViewInfo = OperatorInfo { Pos = { -55, 412.5 } },
      },
      pImageEmitter1SizeOverLife_1 = LUTBezier {
         KeyColorSplines = {
            [0] = {
               [0] = { 0.5, RH = { 0.333333333333333, 0.5 }, Flags = { Linear = true } },
               [1] = { 0.5, LH = { 0.666666666666667, 0.5 }, Flags = { Linear = true } }
            }
         },
         SplineColor = { Red = 192, Green = 128, Blue = 64 },
         CustomData = { Path = { Map = { ["Setting:"] = "Templates:\\MyTemplates\\" } } },
      },
      pImageEmitter1BlurOverLife2D_1 = LUTBezier {
         KeyColorSplines = {
            [0] = {
               [0] = { 0.5, RH = { 0.333333333333333, 0.5 }, Flags = { Linear = true } },
               [1] = { 0.5, LH = { 0.666666666666667, 0.5 }, Flags = { Linear = true } }
            }
         },
         SplineColor = { Red = 192, Green = 128, Blue = 64 },
         CtrlWZoom = false,
         CustomData = { Path = { Map = { ["Setting:"] = "Templates:\\MyTemplates\\" } } },
      },
      pRender1_1 = pRender {
         CustomData = { Path = { Map = { ["Setting:"] = "Templates:\\MyTemplates\\" } }, },
         Inputs = {
            _MotionBlurWarning = Input { Disabled = true, },
            GlobalOut = Input { Value = 274, },
            Width = Input { Value = 1920, },
            Height = Input { Value = 1080, },
            UseFrameFormatSettings = Input { Value = 1, },
            ["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
            OutputMode = Input { Disabled = true, },
            ["MaterialID.MaterialID"] = Input { Value = 1, },
            ["ObjectID.ObjectID"] = Input { Value = 1, },
            Input = Input {
               SourceOp = "pImageEmitter1_1",
               Source = "Output",
            },
         },
         ViewInfo = OperatorInfo { Pos = { -55, 445.5 } },
      },
      Camera3D1_1 = Camera3D {
         CtrlWZoom = false,
         CustomData = { Path = { Map = { ["Setting:"] = "Templates:\\MyTemplates\\" } }, },
         Inputs = {
            ["Transform3DOp.Translate.Y"] = Input { Value = 0.0296292908690038, },
            ["Transform3DOp.Translate.Z"] = Input { Value = 1.14949283415241, },
            PerspFarClip = Input { Value = 1.5, },
            AoV = Input { Value = 60.0000000000002, },
            FLength = Input { Value = 10.2883817969591, },
            ["Stereo.Mode"] = Input { Value = FuID { "OffAxis" }, },
            FilmGate = Input { Value = FuID { "BMD_URSA_4K_16x9" }, },
            ApertureW = Input { Value = 0.831496062992126, },
            ApertureH = Input { Value = 0.467716535433071, },
            ["SurfacePlaneInputs.ObjectID.ObjectID"] = Input { Value = 2, },
            ["MtlStdInputs.MaterialID"] = Input { Value = 2, },
         },
         ViewInfo = OperatorInfo { Pos = { 55, 478.5 } },
      },
      Merge3D1_1 = Merge3D {
         Inputs = {
            SceneInput1 = Input {
               SourceOp = "pRender1_1",
               Source = "Output",
            },
            SceneInput2 = Input {
               SourceOp = "Camera3D1_1",
               Source = "Output",
            },
         },
         ViewInfo = OperatorInfo { Pos = { -55, 478.5 } },
      },
      Renderer3D1_1 = Renderer3D {
         CustomData = { ToolVersion = 2, Path = { Map = { ["Setting:"] = "Templates:\\MyTemplates\\" } }, },
         Inputs = {
            GlobalOut = Input { Value = 274, },
            Width = Input { Value = 192, },
            Height = Input { Value = 256, },
            ["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
            SceneInput = Input {
               SourceOp = "Merge3D1_1",
               Source = "Output",
            },
            RendererType = Input { Value = FuID { "RendererOpenGL" }, },
            ["RendererOpenGL.AntiAliasing.Channels.RGBA.HighQuality.Enable"] = Input { Value = 1, },
            ["RendererOpenGL.AntiAliasing.Presets.Color.Supersampling.HighQuality.RateX"] = Input { Value = 3, },
            ["RendererOpenGL.AntiAliasing.Presets.Color.Supersampling.HighQuality.RateY"] = Input { Value = 3, },
            ["RendererOpenGL.AntiAliasing.Presets.Color.Multisampling.LowQuality.SampleCount"] = Input { Value = 2, },
            ["RendererOpenGL.AntiAliasing.Presets.Color.Multisampling.HighQuality.SampleCount"] = Input { Value = 3, },
            ["RendererOpenGL.AntiAliasing.Presets.Aux.Supersampling.HighQuality.RateX"] = Input { Value = 3, },
            ["RendererOpenGL.AntiAliasing.Presets.Aux.Supersampling.HighQuality.RateY"] = Input { Value = 3, },
            ["RendererOpenGL.AntiAliasing.Presets.Aux.Multisampling.LowQuality.SampleCount"] = Input { Value = 2, },
            ["RendererOpenGL.AntiAliasing.Presets.Aux.Multisampling.HighQuality.SampleCount"] = Input { Value = 3, },
            ["RendererOpenGL.AccumulationEffects"] = Input { Value = 1, },
            ["RendererOpenGL.AccumQuality"] = Input { Value = 32, },
            ["RendererOpenGL.Lighting"] = Input { Value = 0, },
         },
         ViewInfo = OperatorInfo { Pos = { -55, 511.5 } },
         SubInputsData = {
            RendererOpenGL = {
               Version = 1
            }
         }
      }
   },
   ActiveTool = "Camera3D1_1"
}
Online
User avatar

Bryan Ray

  • Posts: 2075
  • Joined: Mon Nov 28, 2016 5:32 am
  • Location: Los Angeles, CA, USA

Re: Why does Particles add transparency?

PostFri Dec 03, 2021 6:05 pm

Yep. Quadruple the size, and the particles will all be solid. This is a really good example of the Nyquist frequency. In a nutshell, the frequency of your details (the size of a particle and that of the gaps between them) must be no more than half as high as the frequency of the "signal" (the number of pixels used to display the particles).

With a render that is too small, the anti-aliasing on your 2-pixel-diameter particles is causing them to be mixed with the surrounding black, creating the mud. If you turn anti-aliasing off in the Renderer3D, you'll see them render closer to what you expect, but some of them are falling in between pixels and don't get their full height. That's what I've done in this image:

Capture.JPG
Capture.JPG (84.93 KiB) Viewed 352 times


The adjusted Renderer3D:
Code: Select all
{
   Tools = ordered() {
      Renderer3D1_1 = Renderer3D {
         CtrlWZoom = false,
         CustomData = { Path = { Map = { ["Setting:"] = "Templates:\\MyTemplates\\" } }, ToolVersion = 2, },
         Inputs = {
            GlobalIn = Input { Value = 1001, },
            GlobalOut = Input { Value = 1279, },
            Width = Input { Value = 192, },
            Height = Input { Value = 256, },
            ["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
            RendererType = Input { Value = FuID { "RendererOpenGL" }, },
            ["RendererOpenGL.AntiAliasing.Nest"] = Input { Value = 1, },
            ["RendererOpenGL.AntiAliasing.Channels.RGBA.LowQuality.Enable"] = Input { Value = 0, },
            ["RendererOpenGL.AntiAliasing.Channels.RGBA.HighQuality.Enable"] = Input { Value = 0, },
            ["RendererOpenGL.AntiAliasing.Presets.Nest"] = Input { Value = 1, },
            ["RendererOpenGL.AntiAliasing.Presets.Color.Supersampling.HighQuality.RateX"] = Input { Value = 3, },
            ["RendererOpenGL.AntiAliasing.Presets.Color.Supersampling.HighQuality.RateY"] = Input { Value = 3, },
            ["RendererOpenGL.AntiAliasing.Presets.Color.Multisampling.LowQuality.SampleCount"] = Input { Value = 2, },
            ["RendererOpenGL.AntiAliasing.Presets.Color.Multisampling.HighQuality.SampleCount"] = Input { Value = 3, },
            ["RendererOpenGL.AntiAliasing.Presets.Aux.Supersampling.HighQuality.RateX"] = Input { Value = 3, },
            ["RendererOpenGL.AntiAliasing.Presets.Aux.Supersampling.HighQuality.RateY"] = Input { Value = 3, },
            ["RendererOpenGL.AntiAliasing.Presets.Aux.Multisampling.LowQuality.SampleCount"] = Input { Value = 2, },
            ["RendererOpenGL.AntiAliasing.Presets.Aux.Multisampling.HighQuality.SampleCount"] = Input { Value = 3, },
            ["RendererOpenGL.AccumulationEffects"] = Input { Value = 1, },
            ["RendererOpenGL.AccumQuality"] = Input { Value = 32, },
            ["RendererOpenGL.Lighting"] = Input { Value = 0, },
         },
         ViewInfo = OperatorInfo { Pos = { 9075, -445.5 } },
         SubInputsData = {
            RendererOpenGL = {
               Version = 1
            }
         }
      }
   },
   ActiveTool = "Renderer3D1_1"
}


You might see this same kind of artifact pop up if you try to make very thin lines. Any line must be at least three pixels in width to appear solid, unless you can place it precisely in the raster grid such that it does not anti-alias. Four pixels is better to completely avoid pulsing and flickering for a line that moves. The same goes for text—your font size can't go too low, or there just aren't enough pixels to render it, and any motion at all will create problems.

edit: Oh, and one other thing. Always turn off Smooth Resize in your Viewers to get the most accurate look at zoomed-in pixels.
Bryan Ray
http://www.bryanray.name
http://www.musevfx.com
Offline

Jinxer

  • Posts: 41
  • Joined: Thu Sep 23, 2021 3:06 pm
  • Real Name: Sergey Zinchenko

Re: Why does Particles add transparency?

PostFri Dec 03, 2021 9:16 pm

Thank you for the clear explanation. When it is not possible to increase the size, how can I better adjust the transparency? Usually, to get the colors back, I reduce High in the Bitmap node. Or I merge the renderer's output with itself using overlay. Don't you know a better way?
Offline

Jinxer

  • Posts: 41
  • Joined: Thu Sep 23, 2021 3:06 pm
  • Real Name: Sergey Zinchenko

Re: Why does Particles add transparency?

PostSat Dec 04, 2021 4:07 pm

I found it! ColorCurves node with Alpha and Pre-Divide/Post-Multiply checked.
Online
User avatar

Bryan Ray

  • Posts: 2075
  • Joined: Mon Nov 28, 2016 5:32 am
  • Location: Los Angeles, CA, USA

Re: Why does Particles add transparency?

PostSun Dec 05, 2021 1:49 am

I personally like a Brightness/Contrast node with the Alpha and Clamp White ticked. Then I adjust the High end of the range slider. You'd probably want to untick the RGB channels, too, in order to preserve the color. And probably use the Pre-divide/Post-multiply, as you did with ColorCurves. But Curves works just fine, too, if that's what's intuitive for you!
Bryan Ray
http://www.bryanray.name
http://www.musevfx.com

Return to Fusion

Who is online

Users browsing this forum: Bryan Ray and 8 guests