POV-Ray : Newsgroups : povray.binaries.scene-files : Filling a bottle with fluid Server Time
24 Apr 2024 18:06:23 EDT (-0400)
  Filling a bottle with fluid (Message 1 to 5 of 5)  
From: Thomas de Groot
Subject: Filling a bottle with fluid
Date: 22 Aug 2012 08:30:02
Message: <5034d0ca@news.povray.org>
The used scene (see p.b.i.)

Thomas


Post a reply to this message


Attachments:
Download 'windows-1252' (7 KB)

From: Le Forgeron
Subject: Re: Filling a bottle with fluid
Date: 22 Aug 2012 17:42:16
Message: <50355238$1@news.povray.org>
Le 22/08/2012 14:29, Thomas de Groot nous fit lire :
> The used scene (see p.b.i.)
> 
> Thomas

Thanks. I found back CIE.inc in some archive, but Gilles Tran include I
hope I do not need, because I do not have.

Adaptation went well, till I get hit by the media, as changing the
container of course changed its distribution (getting both media in the
liquid was not good).
Should be solved with the object pattern in the distribution.

Yet, the liquid is not the same red. Media seems a domain that's doom to
escape me.

Picture in p.b.i once rendered (trace limited to 5 might have an effect
on the reality of the scene)


Post a reply to this message


Attachments:
Download 'fluid_test2.pov.txt' (7 KB)

From: Thomas de Groot
Subject: Re: Filling a bottle with fluid
Date: 23 Aug 2012 03:28:22
Message: <5035db96$1@news.povray.org>
On 22-8-2012 23:42, Le_Forgeron wrote:
> Thanks. I found back CIE.inc in some archive, but Gilles Tran include I
> hope I do not need, because I do not have.

Yeah, I could have trimmed the scene down but was too lazy ;-) Gille's 
include is not important in this kind of scenes; only used to test the 
presence of objects within the camera field.

>
> Adaptation went well, till I get hit by the media, as changing the
> container of course changed its distribution (getting both media in the
> liquid was not good).
> Should be solved with the object pattern in the distribution.
>
> Yet, the liquid is not the same red. Media seems a domain that's doom to
> escape me.

The two media are looking best (?) when they are completely separate of 
course, i.e. when the liquid is slightly smaller than the container, 
which is the standard procedure. But we are talking here about 
alternatives :-) and I think it is a minor problem which only needs some 
more tweaking to get the desired result.

>
> Picture in p.b.i once rendered (trace limited to 5 might have an effect
> on the reality of the scene)

Of course.


Thanks for this code. I had also started experimenting with ellipsoids 
but had not yet got satisfying results.

In your code, I was surprised by the use of object{} within the density 
block. I never thought of that, and I think it is not described as 
option in the Docs (at least I cannot find it). It is comparable to 
object pattern apparently; logical when considering it.

Yet learned another lesson :-)

Thomas


Post a reply to this message

From: Le Forgeron
Subject: Re: Filling a bottle with fluid
Date: 23 Aug 2012 08:38:10
Message: <50362432$1@news.povray.org>
Le 23/08/2012 09:28, Thomas de Groot a écrit :
> 
> In your code, I was surprised by the use of object{} within the density
> block. I never thought of that, and I think it is not described as
> option in the Docs (at least I cannot find it). It is comparable to
> object pattern apparently; logical when considering it.

Well, it is indeed the object pattern. syntax is a bit ambiguous
regarding if "object { Foo ..." is actually :
 1. a new instance of the object Foo
 2. a pattern: object pattern using Foo

It's context sensitive. Density wants a pattern and then a map.
Excepted that a discontinuous pattern have no map, but a list:

http://wiki.povray.org/content/Reference:Object_Pattern

http://wiki.povray.org/content/Reference:Media#Density_with_color_map

Even if it does not cite object, the reference does:

http://wiki.povray.org/content/Reference:Pigment#Color_List_Pigments




PS: I had a little fight with cutaway_textures and the bug of 3.7
regarding it. Hence it's not the obvious:

difference {
 union { A with texture
         B with texture
       }
  C with or without texture
  cutaway_texture
}


Post a reply to this message

From: Thomas de Groot
Subject: Re: Filling a bottle with fluid
Date: 23 Aug 2012 10:32:52
Message: <50363f14$1@news.povray.org>
On 23-8-2012 14:38, Le_Forgeron wrote:
> Le 23/08/2012 09:28, Thomas de Groot a écrit :
>>
>> In your code, I was surprised by the use of object{} within the density
>> block. I never thought of that, and I think it is not described as
>> option in the Docs (at least I cannot find it). It is comparable to
>> object pattern apparently; logical when considering it.
>
> Well, it is indeed the object pattern. syntax is a bit ambiguous
> regarding if "object { Foo ..." is actually :
>   1. a new instance of the object Foo
>   2. a pattern: object pattern using Foo

OK.

>
> It's context sensitive. Density wants a pattern and then a map.
> Excepted that a discontinuous pattern have no map, but a list:
>
> http://wiki.povray.org/content/Reference:Object_Pattern

This is fairly clear, although I had to think twice before understanding 
what is meant by /list/. I am not as smart as I used to be ;-)

>
> http://wiki.povray.org/content/Reference:Media#Density_with_color_map

Again, for the less smart amongst us, using the term /Density List/ 
elsewhere than only in the title would help understanding. I think it 
would be wise also to add /object/ to the list of (four!) list patterns 
where they can be used in density. I would suggest the following 
amendment to the relevant text:

Instead of:
[quote]Entire densities may also be used with the block patterns such as 
checker, hexagon and brick.[/quote]

I would read:
[quote] Density lists may also be used with block patterns such as 
checkers, hexagon and bricks, as well as the object pattern object.[/quote]

...or something equivalent if this is not strictly correct.

>
> Even if it does not cite object, the reference does:
>
> http://wiki.povray.org/content/Reference:Pigment#Color_List_Pigments

Indeed.

>
>
>
>
> PS: I had a little fight with cutaway_textures and the bug of 3.7
> regarding it. Hence it's not the obvious:
>
> difference {
>   union { A with texture
>           B with texture
>         }
>    C with or without texture
>    cutaway_texture
> }
>

right.

Thomas


Post a reply to this message

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