|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Last Night I tried to create a media density pattern based on an object and
failed.
Does anyone know if this is possible?
I noted that the manual says that Object patterns are block patterns, can
these be used in density statements?
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> Last Night I tried to create a media density pattern based on an object
and
> failed.
>
> Does anyone know if this is possible?
That should work fine. If it's not working it's probably for some other
reason.
If I were you, I'd consider, why are you using an object{} density pattern
when you could just use the object as the container for the media itself?
Do you *have* a media container? If not, you should; otherwise it's likely
that the rays are going so far into the distance that they're just not
sampling the area where the visible media resides.
- Slime
[ http://www.slimeland.com/ ]
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> That should work fine. If it's not working it's probably for some other
> reason.
>
> If I were you, I'd consider, why are you using an object{} density pattern
> when you could just use the object as the container for the media itself?
>
> Do you *have* a media container? If not, you should; otherwise it's likely
> that the rays are going so far into the distance that they're just not
> sampling the area where the visible media resides.
>
I want to build a "object" shape for the media so that I can turbulate(real
word?) it.
The shape is/was contained in a larger sphere.
From what you say it seems that I may be having a syntax problem.
I've tried writing it as a pigment function, that can be used in a density
statement, is that the wrong way of going about it?
i.e.
declare myObject
declare myPigment, using myObject
declare myFunction using myPigment
create a sphere with interior media using myFunction as function for
density.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> I want to build a "object" shape for the media so that I can
turbulate(real
> word?) it.
Ah.
> I've tried writing it as a pigment function, that can be used in a density
> statement, is that the wrong way of going about it?
>
> i.e.
>
> declare myObject
> declare myPigment, using myObject
> declare myFunction using myPigment
> create a sphere with interior media using myFunction as function for
> density.
That should work fine, though the creation of myPigment seems unnecessary
when you can simply use myObject directly as a pattern for the density. (I'm
pretty sure you can do just about anything to a density that you can do to a
pigment.)
Did you make the sphere (and all other surrounding objects) "hollow"?
If so, I don't know if we can help you without seeing any code.
- Slime
[ http://www.slimeland.com/ ]
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> If so, I don't know if we can help you without seeing any code.
My code's a mess.
Whats wrong with this snippet?
#declare myObject = union {
cylinder { <8,0,0>,<-8,0,0>,3 }
sphere { <0,0,0>, 5 } } ;
... and then...
density {
object { myObject 0,1 }
}
... I just keep getting various sytax checking errors with everything I
try?
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> density {
> object { myObject 0,1 }
> }
First off, make sure that's within a media {} block. Second, it may be
necessary to use "rgb 0" and "rgb 1" instead of just "0" and "1" (though I'm
not sure that that's the case).
> ... I just keep getting various sytax checking errors with everything I
> try?
What error are you getting?
Here is what I would try:
#declare myObject = ... // you seem to have this part correctly already
sphere { // media container
0, 5
pigment {rgbt 1} // clear
interior {
media {
scattering {1, 1.0} // or emission or absorption or whatever you
want
density {
object {myObject}
warp {turbulence .3}
scale 2
// whatever else
}
}
}
hollow // necessary for media to show up
}
- Slime
[ http://www.slimeland.com/ ]
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Thanks for your help so far Slime, but neither of the examples you've
suggested has hit the nail on the head as it were.
I've included the scene below, hoping you can see the obvious thing I've
missed... Run it to see the current syntax problem...
#include "colors.inc"
camera {
location <0, 5, -40> look_at <0, 0, 0>
}
light_source {<-200, 1000, -400> White}
plane {
y, -20
pigment { color rgb <0.7,0.5,0.3> }
}
#declare myObject = union {
cylinder {
<8,0,0>,
<-8,0,0>,
3
}
sphere {
<0,0,0>
,5
}
};
sphere {
<0,0,0>,
10
texture { pigment { Clear } }
hollow
interior {
media {
scattering {1, 0.1}
intervals 1
samples 5
method 3
density {
object {myObject rgb 0 rgb 1}
}
}
}
}
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> Thanks for your help so far Slime, but neither of the examples you've
> suggested has hit the nail on the head as it were.
> I've included the scene below, hoping you can see the obvious thing I've
> missed... Run it to see the current syntax problem...
After attempting your code, I can see that there is definitely some sort of
problem with using the object pattern in a density block. It doesn't seem to
accept any LIST_ITEM_A/B values as "3.5.11.23 Object Pattern" in the
documentation says it should, and if you don't specify anything then it says
"missing pigment".
I'm not sure if this is intended behavior. Regardless, it can be worked
around with a pigment_pattern:
density {
pigment_pattern {object {myObject 0, 1}}
color_map {[0 rgb 0][1 rgb 1]}
}
Which allows your scene to render.
- Slime
[ http://www.slimeland.com/ ]
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Josh" <som### [at] microsoftcom> wrote:
> density { object {myObject rgb 0 rgb 1} }
using
density { pigment_pattern { object {myObject rgb 1, rgb 0 } } }
seems to work OK.
Hope this helps,
Mike.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> After attempting your code, I can see that there is definitely some sort
of
> problem with using the object pattern in a density block. It doesn't seem
to
> accept any LIST_ITEM_A/B values as "3.5.11.23 Object Pattern" in the
> documentation says it should, and if you don't specify anything then it
says
> "missing pigment".
Yep, thats one of the errors that made me think it was my syntax
>
> I'm not sure if this is intended behavior. Regardless, it can be worked
> around with a pigment_pattern:
>
> density {
> pigment_pattern {object {myObject 0, 1}}
> color_map {[0 rgb 0][1 rgb 1]}
> }
Ah - ha! "pigment_pattern" is a new one on me. There's so much to learn.
Thanks very much for you help it is appreciated. If you add ...
warp {
turbulence <0,3,0>
}
... to the density block, you'll see what I was attempting.
I was inspired by an image someone posted here that used media filled chess
pieces for a "Hollographic" look.
I want to try the same but have the media vaporise when the board gets shut
down. It could be a mighty cool animation.
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |