Announcement

Collapse
No announcement yet.

render element plugin, Intersection / shade / postillum

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • render element plugin, Intersection / shade / postillum

    Hi there,

    Being a newbie to the vray sdk, these might be quite obvious questions.. It was fairly easy to write a simple render element based on the supplied samples, but now i seem to have hit a roadblock.
    The render element i have should not be using transparency compositing of the fragments, as i want the closest fragment's value to be displayed only (so it should ignore reflections / refractions etc. its a matte pass). The example i based my work on was inheriting VRayIntersectionShader and did its shading in the shade() function. However, i dont seem to be able to do anything in there that would make the end result ignore transparency.

    I tried using other examples, where the shading is done in the PostIllum function, but for some reason PostIllum never gets called by vray. I rebuilt some of the examples (like VRayReflectionElement), and even those dont have their PostIllum called. Strange.

    What am i missing?

    cheers,
    laszlo

  • #2
    Nevermind, i've figured it out. I had to overload the addValue function and make sure fbm_ray type blends are only added if flags==0. I had to play with it a fair bit, because by accident i also had faulty code in the shade function.

    oh well.

    Comment


    • #3
      Heh ok, I see you figured it out

      Best regards,
      Vlado
      I only act like I know everything, Rogers.

      Comment


      • #4
        Hehe yeah

        But then, i tried to get fancy. I've actually added 3 additional channels to the image from my render element, managing each with its own instance of a RegionChannelCallback object. It all works great in the vray frame buffer, i see all 4 channels added (first is color, rest 3 are integers) with all the proper values. But it appears that the additional channels arent saved into the EXR file.. I probably shouldn't be doing what i'm doing, right?

        cheers,
        l

        Comment


        • #5
          I did some additional troubleshooting here. It might be a nuke issue. In fusion i see the additional channels (even though they arent integer, but float). In nuke it seems like the 3 channels are merged into one "other" color layer, arbitrarily chosing which is r,g and b.

          Further investigation in progress...

          Comment


          • #6
            nevermind.. im an idiot. Ill just rename this thread 'nevermind'.

            The channels are all there, showing up just fine. They are converted to float, but that probably happens in the comp applications.

            Comment


            • #7


              Best regards,
              Vlado
              I only act like I know everything, Rogers.

              Comment

              Working...
              X