POV-Ray : Newsgroups : povray.general : Broken glass : Re: Broken glass Server Time
2 Aug 2024 02:28:33 EDT (-0400)
  Re: Broken glass  
From: Ross
Date: 17 Feb 2005 00:33:34
Message: <42142cae@news.povray.org>
Maurice wrote:

> Tim Nikias wrote:
>>>I saw this picture:
>>>
>> 
>>
http://www.worldpressphoto.nl/index.php?option=com_photogallery&task=view&id=264&type=byname&Itemid=119&bandwidth=high
>> 
>>>and was wondering how one might render broken glass as shown here.
>> 
>> 
>> Quite complicated stuff. You might want to try and create a mesh of some
>> sort, maybe by deriving this shattered structure from a function using a
>> solid-edged crackle pattern (or probably, a mix of several differently
>> scaled crackles). Cut out the holes with an irregular shape. Either
>> texture the glass properly or put high-density media inside (which would
>> take forever though).
>> 
>> In general, things like "breaking glass" are difficult to pull off and
>> there are universities doing research on this on how to efficiently and
>> properly get virtual glass for various stuff like CG, simulations, etc.
>> Not only are you asking a "simple" breaking glass, you want to take on
>> the entire palette: fractures, cracks, holes... ;-)
>> 
> Hehe. I wasn't worried about the holes. Its the fractures that decrease
> in amount as a function of the distance from a given point that seems to
> be most challenging. I was thinking of some kind of white web of solid
> fractures in a union with a glass plate. But I haven't a clue how to do
> that.
> 
> 

I thought this was kind of interesting. Looking at the image you linked to,
it sort of made me think of "radial lightning" if such a thing exists. so
it's sort of recursive in some aspect. given that, i picked a few points
roughly in a circle. then, subdivided the line connecting each point a few
times, displacing the new point somewhat randomly (but more or less inward
or outward along the vector from the origin to the current point). continue
until you reach some recursion depth, at which point I placed a thin
cylinder connecting the points, since it was the easiest object to place
given two points. do the same to the next line segment, and so on. this
creates the circular cracks. then, i did the same type of subdivision on
segments connecting the origin to each point, and then beyond to some other
point. this creates the spidering cracks running outward from the point of
impact. 

i scaled the cylinders such that they could cut into an object as a
difference. The only problem (and the killer i guess) is that this doesn't
get you the individual pieces of glass that are slightly angled and no
longer in the original plane. it just sort of makes cracks. but it's a
start. I imagine that given all the points and lines connecting them and
lines intersecting each other, the info could be used to create a mesh of
triangles, then the vertices could maybe be perturbed to get the fragmented
look.

i did a test render and the edges of the cracks look good, in my opinion,
but the glass just doesn't have that shattered feel. I need to work on the
random displacement for the crack points, it doesn't quite look natural
yet. another tough part I think would be getting that opaque white look at
the center. but maybe fake it with a texture or media. 


-ross


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.