Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    Volumetric VP or Shader?

    Scheduled Pinned Locked Moved SDK Help
    9 Posts 0 Posters 683 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • H Offline
      Helper
      last edited by

      THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

      On 30/10/2006 at 04:30, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   9.6 
      Platform:   Windows  ; Mac  ;  Mac OSX  ; 
      Language(s) :     C++  ;

      ---------
      Hi,

      I would like to know the difference between a volumetric shader and a volumetric videopost plugin.

      What is the advantage of a videopost implementation and what are the cons?

      Thank you
      Katachi

      1 Reply Last reply Reply Quote 0
      • H Offline
        Helper
        last edited by

        THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

        On 30/10/2006 at 07:38, xxxxxxxx wrote:

        I would say the main advantage is that you can actually attach volume shaders to objects, thus easily define where the volumetric calclations happen. I think you can do this with a videopost plugin too, but it seems easier with shaders. With volumentric shaders you get also some additional functions for instance Displace which you would have to recreate in a videopost plugin.

        cheers,
        Matthias

        1 Reply Last reply Reply Quote 0
        • H Offline
          Helper
          last edited by

          THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

          On 30/10/2006 at 08:24, xxxxxxxx wrote:

          Hi Matthias,

          thanks first of all. What I actually meant was if there are any pros and cons between the two concerning the rendering pipeline. Are there any advantages that a shader is calculated in post instead of in a volume shader?

          The reason I am asking is that when I use TraceGeometry in an environment shader, I am checking for transparencies with GetSurfaceData() and if there is full transparency (for example on a plane with an alpha texture) I simply keep on tracing and check the next location. Now if this hit is fully opaque, I set the transparency and color at that point.

          Works fine but the problem is that this seems to affect the full transparency of the former hit point (so the alpha textured plane). How can I get rid of this behavior, or rather, what is the reason for this behavior?

          Here is some pseudocode:

          while(TraceGeometry(from pStart)){
          GetSurfaceTransparency(pHit)
          if(trans==1.0f)
               pStart = pHit;
          else if(trans!=0.0f)
          {
               SetTransparency&Color;
               pStart = pHit;
          }
          else if(trans==0.f)
               break;

          }

          Check this for an example to see the effect I mean:
          http://www.katachi.de/bug_enviro.jpg
          (there is a slight white border of the plane visible although I am setting vd->trans = 1.0 when there is full transparency)

          Hope this is clearer. Did anybody encounter something like this? It´s really important.

          thank you!

          1 Reply Last reply Reply Quote 0
          • H Offline
            Helper
            last edited by

            THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

            On 08/11/2006 at 13:38, xxxxxxxx wrote:

            I don't know if I'm stupid, but I don't understand the attached picture. What should it look like to be fine? And what is it that we're looking at?

            1 Reply Last reply Reply Quote 0
            • H Offline
              Helper
              last edited by

              THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

              On 08/11/2006 at 15:44, xxxxxxxx wrote:

              you see a plane with a mapped circular gradient on it (from inner white to outer black. the gradient shader is in the alpha channel).

              Usually the inner part (as you can see in the picture) is visible and fades out radially. That works of course.

              Now I have a volumetric environment shader that works as described in the pseudocode.

              I hit the plane, then I check the surface transparency with GetSurfaceData() and if it´s fully opaque, I do my calculations and return. If it´s transparent, I do the calculations and keep on tracing forward. if it´s fully transparent (sd->trans==0.f) then I don´t do any calculations and keep on tracing forward.

              Now, the edges of the plane in the image are fully transparent (sd->trans==0.f) and therefore they should be invisible. But when you look closely, the edges shine a little white (you can identify them in front of the background).

              My environment shader is based on distance of the intersection point to the eye. When there is no background, this effect doesn´t come up. Only when I keep on tracing and hit another object this happens.

              I first thought, it´s a bug in my code, but when I do the same with the environment object´s fog, the same effect happens.

              Find an example scene of the fog problem here:
              Fog Bug

              How can I solve this problem?

              Thanks
              Samir

              1 Reply Last reply Reply Quote 0
              • H Offline
                Helper
                last edited by

                THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

                On 09/11/2006 at 15:38, xxxxxxxx wrote:

                ah, and that´s why I asked the question if there is a difference between VP and Shader implementation. Maybe this effect does not appear in a volumetric VideoPost implementation?

                1 Reply Last reply Reply Quote 0
                • H Offline
                  Helper
                  last edited by

                  THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

                  On 15/11/2006 at 12:05, xxxxxxxx wrote:

                  So, is there a fix now possible or not? I really don´t wanna be impolite, I just think after 2 weeks it should be possible to answer this question or at least give me a "we don´t know" or so. I sore inbetween nothing and less. 😕

                  1 Reply Last reply Reply Quote 0
                  • H Offline
                    Helper
                    last edited by

                    THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

                    On 16/11/2006 at 00:51, xxxxxxxx wrote:

                    Let me just say at least that I've looked at the fog file and can confirm that there is a visible border. It seems to me that there is less fog is the fog goes in two segments (cam -> plane -> floor) than one (cam -> floor). That makes me suspicious that perhaps something is not linear when adding the transparencies up, so that .1 + .1 < .2. It's even clearer when you have multiple planes in front of each other. I don't have any answer, but I'll have to think about this more tonight!

                    1 Reply Last reply Reply Quote 0
                    • H Offline
                      Helper
                      last edited by

                      THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

                      On 24/11/2006 at 01:34, xxxxxxxx wrote:

                      So, have you thought about it? I NEED an answer.

                      1 Reply Last reply Reply Quote 0
                      • First post
                        Last post