Difference between revisions of "User:Le Forgeron/HowTo/Perfect glass"
< User:Le Forgeron | HowTo
Jump to navigation
Jump to search
Le Forgeron (talk | contribs) |
Le Forgeron (talk | contribs) (→Start) |
||
Line 41: | Line 41: | ||
The straw is just a bonus to check the actual effect of the variation of the index of refraction (ior) between normal space (1.0) and the transparent material of the glass (find many in glass.inc). | The straw is just a bonus to check the actual effect of the variation of the index of refraction (ior) between normal space (1.0) and the transparent material of the glass (find many in glass.inc). | ||
|} | |} | ||
+ | |||
+ | <pre> | ||
+ | cylinder { ... | ||
+ | hollow | ||
+ | material { glas } | ||
+ | } | ||
+ | </pre> | ||
===Time for CSG=== | ===Time for CSG=== |
Revision as of 16:24, 30 September 2012
Perfect glass
Welcome, if you are tired of coincident surface in your non opaque fluid containers, it might be the right place.
An easy test, as multiple-choice questions, to check the lesson of today:
- How do you make an empty plate ?
- You select a material, a shape and combine both.
- How do you make an empty glass ?
- You select a material, a shape and combine both.
- How do you put a cake on a plate ?
- Take the plate and and move the cake to the plate.
- How do you fill a glass with a liquid ?
- Take the empty glass and pour the liquid, well put the liquid in a suitable shape and move it to the glass.
- Mu. This is a non-sense.
The right answer is 2: to achieve a glass with some liquid, you should not start with an empty glass.
If you start with a filled glass, you might end with an empty glass. But the reversal is bogus: you would get coincident surface and its noise.
From right to left:
- an empty glass
- an half-filled flass
- a full glass
- something that need to be explained
Start
cylinder { ... hollow material { glas } }
Time for CSG
To make an empty glass, we now remove from the block of glass the internal volume to be filled by the air.
difference { cylinder { ... hollow material { glas } } cylinder { ... hollow material { air } } cutaway_textures }
We hear you: "Yes, great. Nothing new under the sun so far!"