Page 1 of 1

Projection with alpha is black on geometry

PostPosted: Sun Feb 17, 2019 10:41 pm
by ThomasManz
First time working with projection.
I have an image of a tree trunk which naturally has a rugged edge, which is cut out with alpha. I wanted to project that onto a simple Shape 3D Cylinder. The cylinder of course has clean straight edge. When I now project the trunk image onto the cylinder everywhere there is alpha in the trunk image there is black on the catching cylinder. In Nuke, as far as I remember, when you project something with alpha onto a geometry, wherever there is alpha in the image the catching geometry will be transparent as well. Is there a way to achieve that in Fusion?

Re: Projection with alpha is black on geometry

PostPosted: Mon Feb 18, 2019 2:03 pm
by Frank Feijen
How did you set this up?
It works for me when I project as a texture:
Code: Select all
{
   Tools = ordered() {
      Merge1 = Merge {
         Inputs = {
            Background = Input {
               SourceOp = "Background1",
               Source = "Output",
            },
            Foreground = Input {
               SourceOp = "Text1",
               Source = "Output",
            },
            PerformDepthMerge = Input { Value = 0, },
         },
         ViewInfo = OperatorInfo { Pos = { 220, 247.5 } },
      },
      Text1 = TextPlus {
         Inputs = {
            Width = Input { Value = 1920, },
            Height = Input { Value = 1080, },
            ["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
            Font = Input { Value = "Open Sans", },
            StyledText = Input { Value = "Tree trunk", },
            Style = Input { Value = "Bold", },
            ManualFontKerningPlacement = Input {
               Value = StyledText {
                  Array = {
                  },
                  Value = ""
               },
            },
         },
         ViewInfo = OperatorInfo { Pos = { 110, 247.5 } },
      },
      Background1 = Background {
         Inputs = {
            Width = Input { Value = 1920, },
            Height = Input { Value = 1080, },
            ["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
            TopLeftAlpha = Input { Value = 0, },
         },
         ViewInfo = OperatorInfo { Pos = { 110, 214.5 } },
      },
      Projector3D1 = LightProjector {
         Inputs = {
            ["Transform3DOp.Translate.Z"] = Input { Value = 3.85, },
            ProjectiveImage = Input {
               SourceOp = "Merge1",
               Source = "Output",
            },
            ProjectionMode = Input { Value = 2, },
            ["ShadowLightInputs3D.ShadowsEnabled"] = Input { Value = 0, },
         },
         ViewInfo = OperatorInfo { Pos = { 275, 148.5 } },
      },
      Renderer3D1 = Renderer3D {
         CtrlWZoom = false,
         CustomData = {
            ToolVersion = 2,
         },
         Inputs = {
            Width = Input { Value = 1920, },
            Height = Input { Value = 1080, },
            ["Gamut.SLogVersion"] = Input { Value = FuID { "SLog2" }, },
            SceneInput = Input {
               SourceOp = "Merge3D2",
               Source = "Output",
            },
            ["RendererSoftware.LightingEnabled"] = Input { Value = 1, },
            ["RendererSoftware.ShadowsEnabled"] = Input { Value = 1, },
         },
         ViewInfo = OperatorInfo { Pos = { 440, 82.5 } },
      },
      Merge3D2 = Merge3D {
         Inputs = {
            SceneInput1 = Input {
               SourceOp = "Shape3D1",
               Source = "Output",
            },
            SceneInput2 = Input {
               SourceOp = "Projector3D1",
               Source = "Output",
            },
         },
         ViewInfo = OperatorInfo { Pos = { 275, 82.5 } },
      },
      Catcher1 = TexCatcher {
         Inputs = {
            MaterialID = Input { Value = 4, },
         },
         ViewInfo = OperatorInfo { Pos = { 55, 82.5 } },
      },
      Shape3D1 = Shape3D {
         Inputs = {
            Shape = Input { Value = FuID { "SurfaceCylinderInputs" }, },
            MaterialInput = Input {
               SourceOp = "Catcher1",
               Source = "MaterialOutput",
            },
            ["MtlStdInputs.MaterialID"] = Input { Value = 2, },
            ["SurfacePlaneInputs.ObjectID.ObjectID"] = Input { Value = 2, },
            ["SurfaceCylinderInputs.ObjectID.ObjectID"] = Input { Value = 4, }
         },
         ViewInfo = OperatorInfo { Pos = { 165, 82.5 } },
      }
   }
}

Re: Projection with alpha is black on geometry

PostPosted: Tue Feb 19, 2019 7:40 am
by ThomasManz
Nice. :D
Meanwhile I found a solution which involves a UV Map 3D and an extra Camera but your setup works much better for me. It's much easier to read.
Thanks.