|
|
VRay 1.5: Embedded Surface Gets Rendered
About Truespace Archives
These pages are a copy of the official truespace forums prior to their removal somewhere around 2011.
They are retained here for archive purposes only.
VRay 1.5: Embedded Surface Gets Rendered // New Users
Post by JPSofCA // May 27, 2007, 5:34am
|
JPSofCA
Total Posts: 300
|
I did this test render with VRay 1.5 to see if an object with the exact same material (the upside-down happy face) inside of another object (the box) would render as a seperate object when transparency is used.
It does.
Is this supposed to happen? |
Post by Jack Edwards // May 27, 2007, 4:23pm
|
Jack Edwards
Total Posts: 4062
|
I'd like to help, but I'm not sure I follow... :confused:
-Jack. |
Post by JPSofCA // May 27, 2007, 4:40pm
|
JPSofCA
Total Posts: 300
|
If I wanted to make a complex glass object from several objects without booleaning things together, you would see the edges of objects inside of others.
I was just wondering if that's apropriate behavior or not. Theoretically, so long as I don't minus the happyface from inside the cube it should render as a solid object, no?
I post it here instead of bugs because I don't know if it's meant to be that way. If it is, I can live with it.
Sometimes I ask questions I already know the answer to. |
Post by kena // May 27, 2007, 4:45pm
|
kena
Total Posts: 2321
|
So, are you saying that the happyface is not set with glass properties? or that it is, but something else is not correct? |
Post by JPSofCA // May 27, 2007, 4:51pm
|
JPSofCA
Total Posts: 300
|
The happyface and the cube are identical materials... |
Post by Jack Edwards // May 27, 2007, 4:52pm
|
Jack Edwards
Total Posts: 4062
|
Also are you using transparency mapping or transmission?
Edit: LOL crossed posts. :)
Have you tried it with single-sided selected?
-Jack. |
Post by Jack Edwards // May 27, 2007, 4:55pm
|
Jack Edwards
Total Posts: 4062
|
Oh I think I get it. Are you saying that you clicked "VRay render object"?
-Jack. |
Post by JPSofCA // May 27, 2007, 5:33pm
|
JPSofCA
Total Posts: 300
|
In the first picture when I render the scene in VRay, that's the result. You can see the same scene behind the rendered window.
The happy face is inside of the cube.
Should I not just see a transparent blue cube?
Why am I seeing the happy face is all I was wondering. |
Post by kena // May 27, 2007, 7:20pm
|
kena
Total Posts: 2321
|
because the happy face doubles the material where it lies. basically, it's just like puting a colored clear object in a colored glass of water. the object is seen. I'm not sure how you would change the happyface to make it go away. sounds like Jack may be the correct person to help you with this. I'm very new to Vray |
Post by JPSofCA // May 27, 2007, 7:28pm
|
JPSofCA
Total Posts: 300
|
I wasn't so much looking for a solution to anything. It's more a curiosity of the principles of why it does what it does, more philosophical than anything.
I didn't mean to draw anyone's attention too much into this one [sorry]...probably would have been best to have not even brought it up - the time we could have spent experimenting with it rather than trying to decipher my rambling on about something like this.
:banana:
Nitpiking is all I'm doing...just nitpicking. :( |
Post by weaveribm // May 28, 2007, 1:36am
|
weaveribm
Total Posts: 592
|
nitpicking
Brainstorming rather JPS and interesting. Chatting about stuff in a pub environment :) can only help us understand stuff and is quite stimulating. The brainstorming not the beer. Beer's not a stimulant. Not the way I use it anyway :)
Peter |
Post by kena // May 28, 2007, 5:08am
|
kena
Total Posts: 2321
|
It's always good to stimulate the brain. Once it was understood what you wer erefering to, answering your question not only helps set it in other people's mind, but also lets you know what can and cannot be expected. :D No question is wasted. |
Post by nowherebrain // May 28, 2007, 3:50pm
|
nowherebrain
Total Posts: 1062
|
Well the reason is the same as if it were reflecting...the cube's face that you see through doesn't really exist. It is a projection of pixels at the camera and those pixels are semi opaque. Therefore the object on the other side/inside in this case, does not perceive it's existence and is projecting it's pixels at the camera...this is the simplest way I can describe it. If the smiley was reflective it would not reflect that face between the camera and itself, unless the cube were projecting in the other direction as well(double sided).
...I lost myself:confused: , too much beer. |
Post by weaveribm // May 29, 2007, 12:18am
|
weaveribm
Total Posts: 592
|
Therefore the object on the other side/inside in this case, does not perceive it's existence and is projecting it's pixels at the camera
Ice for example would need a different index of refraction from liquid water to be seen submerged in water if the ice and water were perfectly without dust or air bubbles. When light passes from one medium to another it refracts (gets bent) at the surface created by the two materials as it passes from one transmitting material to another
Is that what you mean :)
Peter |
Post by nowherebrain // Jun 10, 2007, 12:54pm
|
nowherebrain
Total Posts: 1062
|
NO!, do you guys ever listen!!!!!:D
seriously, if you were responding to me.
the "big box" is projecting it's pixels at the camera.
the "small box" is projecting it's pixels at the camera, but because "big box" is single sided(only projecting in one direction, toward the camera) "small box" does not even acknowledge "big box", and "big box" cannot reflect "small box" since it is not "scaning" or shooting rays, so to speak, in "small boxes" direction. |
Post by TomG // Jun 11, 2007, 3:02am
|
TomG
Total Posts: 3397
|
It's correct and normal behavior in rendering for the happy face to appear.
Materials are not treated as volumes, but as surfaces. Once the raytracing passes through the outside face of the cube and into the cube itself, the ray does not become "different" and does not "remember" that it is now inside the volume of the cube.
So, when it intersects the surface of the smiley face, it acts just the same as when it intersected the surface of the cube. There is no "but now I am travelling through a material with a different refractive index than air" in the calculation.
As noted this is because objects in rendering are treated as surfaces and not as solids.
Now you can go ahead and simulate the effect of your happy face being the same material with the same refractive index, by giving it a refractive index of 1 (ie, no change, do not bend the light). You would have to recalculate the refractive index for yourself though, manually (figuring out that it should be 1 in this case is of course trivial, but if you wanted to say "embed an object with the refractive index of diamond inside a glass object" then you'd need to do some math to figure out what value to use to simulate this effect).
So, the ray is always treated as if it is coming from air whenever it hits a surface. This is normal in rendering, so your result of the smiley face being visible is also normal :)
BTW if you wanted to simulate air bubbles inside the material, this is easier - you can either reverse the normals and make it the glass material again (the reversed normals make the calculation to refract the light work as if it was "move from glass material to air"; I think you can also just make the value as much less than 1 than it was greater than 1, ie if the glass is an index of 1.5, then make your air bubble an index of 0.5, and do this in place of reversing the normals).
Finally, note the above discussions the transmission and refractive index, and not the things like diffuse and specularity. Those will always render, again since objects are treated as surfaces. To simulate "a piece of identical material embedded inside the same material" you would need to manually make those zero to accurately reflect the fact that there is really no surface there :)
HTH!
Tom |
Post by weaveribm // Jun 13, 2007, 12:01pm
|
weaveribm
Total Posts: 592
|
Very interesting and stimulating Tom thanks
note the above discussions the transmission and refractive index, and not the things like diffuse and specularity.
Transmission and refractive indices are material properties and diffuse and specularity are about the surface of a material, is it called surfacing or rendering maybe. I say this Tom because when starting out it's a bit confusing, the difference between an object's material and the object's surface. They're both ray tracing. Transparency as a property of an object is fascinating: trying to work out why light should pass through water but not through wood. Something to do with how in crystals there are many tunnels in the matrix between the molecules and their attachment points and the light ray slips through the gaps. But then how to understand liquid water :)
Those will always render, again since objects are treated as surfaces. To simulate "a piece of identical material embedded inside the same material" you would need to manually make those zero to accurately reflect the fact that there is really no surface there
If an object made of transparent material sat inside another object made of the same material (of exactly the same refractive index therefore) light rays wouldn't be deflected at the inner object's surface it would pass without delay so the inner object would be invisible
if you wanted to say "embed an object with the refractive index of diamond inside a glass object" then you'd need to do some math to figure out what value to use to simulate this effect)
There are tables of refractive indices around too
giving it a refractive index of 1 (ie, no change, do not bend the light)
Ah so that's what the refractive index really is- thanks Tom. Always seemed mysterious that did but the unit is a straight line then and 1.37 say is (represents, but probably not 0.37 degrees that would be too simple?) the angle through which the light bends as it passes from one medium to another. Nice one :)
if you wanted to simulate air bubbles inside the material, this is easier - you can either reverse the normals and make it the glass material again (the reversed normals make the calculation to refract the light work as if it was "move from glass material to air"; I think you can also just make the value as much less than 1 than it was greater than 1, ie if the glass is an index of 1.5, then make your air bubble an index of 0.5, and do this in place of reversing the normals
I can't wait to know enough to understand this, it's really juicy though I can tell. Tom are normals light rays that head off from the surface of a material at an angle er, like a lamp post or a flagpole please? 90 degrees to the surface? I know they're important from graphics cards. Goodness only knows what a reversed normal is... Sorry for working you so hard! :)
Ah diamonds would have a high refractive index then because they bounce light around more inside their material? I could be completely wrong but I have to be brave :)
Peter |
Post by TomG // Jun 13, 2007, 12:25pm
|
TomG
Total Posts: 3397
|
It's a very interesting topic, I am "fairly knowledgeable" but not an "expert" - so someone should correct me if I get it wrong any place.
I can't recall what 1.37 translates to in terms of the angle you get when passing from air (1.0) into a material with 1.37 refractive index. I think I knew once, but not right at this instant :) I have no doubt someone can tell me though - I don't think it is as simple as 0.37 degrees though, would be nice if it was eh? :)
Normals are indeed the line at right angles to the surface. Basically it tells you the direction the surface is pointing in. This then lets you work out things like the angle the ray of light from a light sourcing is hitting the surface at, and the angle at which the line of sight from the viewer is hitting the surface at.
Note that normals at points on the surface get manipulated in all sorts of ways so they are not always right angles to the actual geometry. Applying Smoothing in the material means that calculations are done to figure out the normal at any given point on the surface, so even if the point is in a of a flat face, then it is not necessary pointing straight out from that geometry. Other things like bump maps and normal maps also adjust the normal at any given point.
So the normal is the angle of the surface you are simulating, rather than just the normal of the mesh itself... if any of that is making sense..... :)
A reversed normal is one that is pointing in the opposite direction. Most faces only have one side, so they have one normal pointing out from that side. If you view them in 3D from the other side, they simply disappear - the ray from the eye goes straight through them. No normal pointing in some direction back toward the eye means there is nothing there :)
Reversing the normal makes that the opposite, so the normal faces the other way.
If you think of a sphere, all its normals point outward. View it from inside, its as if it isn't there, because the normals point outward to give the sphere solidity from the outside. Reversing the normals reverses that effect, and makes the normals point inward.
For refraction, this "inverts" the effect - so if the object has a refractive index of glass, and its normals point outward, then a ray entering it is bent as if moving from air, to glass. Inverting the normal turns this calculation upside down, so that it becomes as if moving from glass, to air.
You can however leave the normal in the same direction, and just change the refractive index, and get the same result :)
HTH!
Tom |
|