POV-Ray : Newsgroups : povray.general : Trouble with coincident surface in a CSG merge : Re: Trouble with coincident surface in a CSG merge Server Time
29 Jul 2024 04:30:31 EDT (-0400)
  Re: Trouble with coincident surface in a CSG merge  
From: Anthony D  Baye
Date: 7 Mar 2013 12:30:00
Message: <web.5138cd7f6a8d59d3d97ee2b90@news.povray.org>
"Sohcahtoa" <kil### [at] yahoocom> wrote:
> I'm currently working on a program that converts a Minecraft world into a
> POV-Ray scene, and I'm having real trouble with water.
>
> To make water blocks act like a solid object so that I don't see the sides of
> each block, I take all the water blocks in the world and put them into a CSG
> merge object, which in theory should make them solid.  Unfortunately, it isn't
> working out that way.
>
> If each block in the merge is exactly 1 unit wide, then I get lots of odd pixels
> where the water meets the land underwater.  This is understandable, since the
> water block edge is coincident with the land block.  So as a work-around, I
> tried making each water block slightly large (1.02 blocks wide), but this
> creates odd seams at the surface of the water.
>
> Example renders are at http://imgur.com/a/rCDCG
>
> A couple notes about my scene:
> - Vertical runs of the same block type are saved as a single tall box object to
> reduce the number of objects in the scene.
> - The hole in the world is from an optimization that stops looking for blocks
> below a certain y-coordinate, again, to reduce objects.
>
> Any ideas how to fix the coincident surface problem where the water meets land
> without create a coincident surface problem at the surface of the water without
> manually creating a mesh?

I would think it would be easiest to convert each mass of different block types
into a single mesh by mapping the corner vertices.  make each mass smaller than
it has to be by some tolerance value.  The problem I see with this is changes in
ior when going from water to air, it might make the blocks under the water
render improperly.

One thing you could try is shifting water vertices down and outward, so that
they pass a little under the surface of surrounding blocks.

Are you planning to model everything, or only the surface?  Your conversion
files will be awfully large if you model everything.

Regards,
A.D.B.


Post a reply to this message

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