|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Hi,
I have problem with my scene. I posted here full source and link to images.
Problem is with glass texture. Everything is o.k., until I add dispersion.
I want to get nice rainbow (photons+dispersion). But adding dispersion
makes glass very dark, even at pigment color rgbf 1 (without dispersion it
is totaly clear ofcourse).
Is there some way to add filter to dispersion effect ? btw. how can I get
rid of that yellow sircle around lower-right part of glass ?
IMHO it would be good idea to allow setting diffrent dispersion that is
used to calculate glass color, and diffrent to calcualate photons.
How can I both have nice rainbow photons on gray bacground, and have very
clear glass (like color rgbf .99)
With dispersion http:\\www.raf256.com\t\a4_1.jpg
Without dispersion http:\\www.raf256.com\t\a4_2.jpg
Most important - glass material :
---8<-------------------------------------------------------------
texture {
pigment { color rgbf 1 /*<.93,.98,.999, .98>*/ }
finish {
specular .8 roughness 0.001
//phong 0.4 phong_size 140
reflection { .03 .11 }
diffuse .60
ambient 9
}
}
interior {
ior 1.70 fade_power 1 fade_distance 50
dispersion 1.4 dispersion_samples QQ_Disp // <== PROBLEM
}
---8<-------------------------------------------------------------
DD_Disp is 6..60 - it makes no important change.
Full source (a4.pov) You can copy/paste it, it only needs file "a.inc" -
look at end of this post
---8<-------------------------------------------------------------
/*
P-111 MGlass (scan) buton (class A)
1:1 ratio
started 20.07.2002, last ver 0.50 21.07.2002 for 3.5win
,-,
/o \
| |
\ /.
'-'\\
\\
\\
\\
*/
#declare QQ_Rad = 0; // 0,1,2 3,4,5 light sphere
#declare QQ_Phot = 1.00; // 0=off n.=spacing lower is better good 0.1
//final 0.04
#declare QQ_Disp = 0.10 * 60; // dispersion samples
#declare QO_BackGr = 1;
#declare OF_MGlass = 1;
#declare CfgBackgrTest=0;
#declare CfgAreaSize=4000;
#declare CfgCamRotate =<0,0,0>;
#declare CfgCamRotateP=<0,0,20>;
//plane { z,35 pigment { checker color rgb 0 color rgb 1 } scale 2 }
#declare objGlass = union {
#declare matGlass = material {
texture {
pigment { color rgbf 1 /*<.93,.98,.999, .98>*/ }
finish {
specular .8 roughness 0.001
//phong 0.4 phong_size 140
reflection { .03 .11 }
diffuse .60
ambient 9
}
}
interior {
ior 1.70 fade_power 1 fade_distance 50
dispersion 1.4 dispersion_samples QQ_Disp
}
}
#declare matMetall = material {
texture {
pigment { color rgb .9 }
finish { specular 0.9 roughness 0.010 reflection { .1 .3 metallic }
diffuse .85
}
}
}
#declare matHandleWood = material {
texture {
#declare _c1 = <1.00,0.70,0.55> * 0.70;
#declare _c2 = <1.00,0.80,0.65> * 0.95;
#if (1)
pigment { wood rotate x*90 scale .08 turbulence .05 translate 12
color_map{
[0.00 color rgb _c1]
[0.30 color rgb _c1]
[0.70 color rgb _c2]
[1.00 color rgb _c2]
}
} #else pigment { color rgb 1 } #end
normal { wood rotate x*90 scale .08 turbulence .05 translate 12 }
finish {
specular .6 roughness 0.03
phong 0.6 phong_size 20
brilliance 1.3 diffuse 0.85
}
}
}
#declare _R = 5.2 ; // glass radius
#declare _RTh = 0.45; // ring around glass R-Thickness
#declare _RRo = _R+_RTh/2; // radius of Ring - outer
#declare _RRi = _R-_RTh/2; // radius of Ring - inner
#declare _RH = 0.7; // ring (metal) height
intersection { // main GLASS
sphere { -z*10 12 }
sphere { +z*10 12 }
cylinder { -z*100, +z*100, _R }
material { matGlass }
photons{ reflection on refraction on target }
}
// ring around glass
union{
difference {
cylinder { -z*_RH, +z*_RH, _RRo }
cylinder { -z*(_RH+.1), +z*(_RH+.1), _RRi }
}
torus { _R _RTh/2 rotate x*90 translate +z*_RH }
torus { _R _RTh/2 rotate x*90 translate -z*_RH }
material { matMetall }
photons{ reflection on refraction off target }
}
// Hand
#declare objHand = union {
//cone { 0, 1, -y*8, 1 }
sor {
9
<1.00 ,-1>
<1.00,0>
<0.90,0.50>
<1.00,1.50>
<1.10,3.00>
<1.10,4.50>
<1.05,6.00>
<1.00,8.00>
<1.00,9.50>
sturm
scale <1,-1,1>
}
sphere { -y*8 1 }
scale 0.93*<1.25, 1.25, 0.9>
translate -y*_R
material { matHandleWood }
}
object { objHand }
rotate x*5
rotate z*40
scale 3.2
translate z*100
translate <-13,13,0>
// translate z*100
// translate <-10,10,0>
}
object { objGlass }
#include "a.inc"
---8<-------------------------------------------------------------
some lines with comments may word-arp, so this file is alsow on
http:\\www.raf256.com\t\a4.pov
http:\\www.raf256.com\t\a4.txt (same file just different extension)
NEEDED INCLUDE FILE - a.inc containing radiosity / photons settings and
background plane is here :
http:\\www.raf256.com\t\a.inc
http:\\www.raf256.com\t\a.txt (same file just different extension)
--
#macro g(U,V)(.4*abs(sin(9*sqrt(pow(x-U,2)+pow(y-V,2))))*pow(1-min(1,(sqrt(
pow(x-U,2)+pow(y-V,2))*.3)),2)+.9)#end#macro p(c)#if(c>1)#local l=mod(c,100
);g(2*div(l,10)-8,2*mod(l,10)-8)*p(div(c,100))#else 1#end#end light_source{
y 2}sphere{z*20 9pigment{function{p(26252423)*p(36455644)*p(66656463)}}}//M
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
> dispersion 1.4 dispersion_samples QQ_Disp // <== PROBLEM
1.4 is quite high for dispersion, realistic values are in the range of 1.01
or so. 1.1 can give nice but unrealistic results. The dispersion value is
basically the ratio of the ior for red to the ior for violet for a given
material. I have an ior include file that has iors and dispersion values
for a lot of different materials and that is essentially how the values
look:
ior = (ior_red+ior_violet)/2
dispersion = ior_red/ior_violet
-tgq
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
In article <3d3af599@news.povray.org>,
"TinCanMan" <Tin### [at] hotmailcom> wrote:
> > dispersion 1.4 dispersion_samples QQ_Disp // <== PROBLEM
>
> 1.4 is quite high for dispersion, realistic values are in the range of 1.01
> or so. 1.1 can give nice but unrealistic results. The dispersion value is
> basically the ratio of the ior for red to the ior for violet for a given
> material. I have an ior include file that has iors and dispersion values
> for a lot of different materials and that is essentially how the values
> look:
>
> ior = (ior_red+ior_violet)/2
> dispersion = ior_red/ior_violet
Also, consts.inc has dispersion values defined for quartz glass, water,
diamond, and sapphire.
Unrealistic values can give interesting effects though...in
newdiffract.pov I used 0.1.
--
Christopher James Huff <chr### [at] maccom>
POV-Ray TAG e-mail: chr### [at] tagpovrayorg
TAG web site: http://tag.povray.org/
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"TinCanMan" <Tin### [at] hotmailcom> wrote in
news:3d3af599@news.povray.org
> 1.4 is quite high for dispersion, realistic values are in the range of
> 1.01 or so. 1.1 can give nice but unrealistic results. The
> dispersion value is basically the ratio of the ior for red to the ior
> for violet for a given material. I have an ior include file that has
> iors and dispersion values for a lot of different materials and that
> is essentially how the values look:
> ior = (ior_red+ior_violet)/2
> dispersion = ior_red/ior_violet
I partialy fixed problems - the filter in pigment was too big, and ambient
was almost ignored.
But still - why using even dispersion 1.00001 makes objct _much_ brighter -
so I have to change amient from 0.0 to about 1.0 to have simmilar results
as with no dispersion
Now I use following material, and it gives nice results
texture {
pigment { color rgbf <.93,.98,.999, .98> }
finish {
specular .8 roughness 0.001
phong 0.2 phong_size 20
reflection { .03 .11 }
diffuse .60
ambient 2
}
}
interior {
ior 1.70 fade_power 1 fade_distance 50
dispersion 1.2 dispersion_samples QQ_Disp
}
--
#macro g(U,V)(.4*abs(sin(9*sqrt(pow(x-U,2)+pow(y-V,2))))*pow(1-min(1,(sqrt(
pow(x-U,2)+pow(y-V,2))*.3)),2)+.9)#end#macro p(c)#if(c>1)#local l=mod(c,100
);g(2*div(l,10)-8,2*mod(l,10)-8)*p(div(c,100))#else 1#end#end light_source{
y 2}sphere{z*20 9pigment{function{p(26252423)*p(36455644)*p(66656463)}}}//M
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Rafal 'Raf256' Maj" <raf### [at] raf256com> wrote in
news:Xns### [at] 204213191226
> But still - why using even dispersion 1.00001 makes objct _much_
> brighter - so I have to change amient from 0.0 to about 1.0 to have
much DARKER ofcourse :)
btw. will news.povray.org allow supersede messages ?
--
#macro g(U,V)(.4*abs(sin(9*sqrt(pow(x-U,2)+pow(y-V,2))))*pow(1-min(1,(sqrt(
pow(x-U,2)+pow(y-V,2))*.3)),2)+.9)#end#macro p(c)#if(c>1)#local l=mod(c,100
);g(2*div(l,10)-8,2*mod(l,10)-8)*p(div(c,100))#else 1#end#end light_source{
y 2}sphere{z*20 9pigment{function{p(26252423)*p(36455644)*p(66656463)}}}//M
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
When using photons, you should add 'collect off' to the photon block of
your glass objects.
see 6.10.4 and 6.10.2
-tgq
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Another little piece of advice (if you are using 3.5):
in your camera declaration use:
up y
right x*image_width/image_height
the image proportions don't get distorted if you change the aspect ratio of
the output file, it gets calculated automatically.
-tgq
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"TinCanMan" <Tin### [at] hotmailcom> wrote in
news:3d3b0ec3$1@news.povray.org
> When using photons, you should add 'collect off' to the photon block of
> your glass objects.
collect off will make glass same, or darker, while I want to make it
brighter.
--
#macro g(U,V)(.4*abs(sin(9*sqrt(pow(x-U,2)+pow(y-V,2))))*pow(1-min(1,(sqrt(
pow(x-U,2)+pow(y-V,2))*.3)),2)+.9)#end#macro p(c)#if(c>1)#local l=mod(c,100
);g(2*div(l,10)-8,2*mod(l,10)-8)*p(div(c,100))#else 1#end#end light_source{
y 2}sphere{z*20 9pigment{function{p(26252423)*p(36455644)*p(66656463)}}}//M
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
"Rafal 'Raf256' Maj" <raf### [at] raf256com> wrote in
news:Xns### [at] 204213191226
Hi,
after some tests with this magnifing glass, I think I found a bug in
dispersion + photons + filter objects.
My image looks different in mosaic preview then in single-pass render !
The final mosaic step (1x1) is identical to single-pass, BUT mosaic steps
(2x2, 4x4, etc) - look different. IMHO 2x2 looks correct, while 1x1 image
have bug.
The problem is 'clearness' (filter) of glass. It sometimes look like glass,
sometimes like plastic with very low filter like .2
2x2 mosaic, dispersion 1.3 - nice glass (OK)
1x1 mosaic, dispersion 1.3 - plastic glass (wrong)
2x2 mosaic, no ispersion - nice glass (OK)
1x1 mosaic, no dispersion - nice glass (OK)
look at image posted to .b.i (under Magnyfing glass subject) it's upper
half is with 1x1 mosaic (plastic-glass) and lower part is 2x2 mosaic (nice
glass).
same image: http:\\www.raf256.com\b\a4_pre.jpg
--
#macro g(U,V)(.4*abs(sin(9*sqrt(pow(x-U,2)+pow(y-V,2))))*pow(1-min(1,(sqrt(
pow(x-U,2)+pow(y-V,2))*.3)),2)+.9)#end#macro p(c)#if(c>1)#local l=mod(c,100
);g(2*div(l,10)-8,2*mod(l,10)-8)*p(div(c,100))#else 1#end#end light_source{
y 2}sphere{z*20 9pigment{function{p(26252423)*p(36455644)*p(66656463)}}}//M
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
|
|