POV-Ray : Newsgroups : povray.general : no_image, no_shadow, no_reflection, no_etc... Server Time
6 Nov 2024 18:24:41 EST (-0500)
  no_image, no_shadow, no_reflection, no_etc... (Message 1 to 4 of 4)  
From: Slime
Subject: no_image, no_shadow, no_reflection, no_etc...
Date: 25 Jul 2002 20:17:19
Message: <3d40950f@news.povray.org>
A while ago, someone posted an image of a sphere next to a mirror, and they
wanted the sphere's shadow to be invisible outside the mirror but not inside
it. no_shadow didn't give them that flexability. This got me thinking.
Surely there must be a more flexible way to specify when shadows,
reflections, and images of objects should occur.

More recently, a solution popped into my head. I haven't really quite
figured out the ideal syntax, but this is the gist of what it would look
like:

sphere {
 0,1
 pigment{rgb 1}

 detection {
   never_detect {
    /* a regular expression sort of string specifying what sort of rays
should detect this object */
    [rs] /* any ray that has been reflected earlier in its lifetime or is a
shadow ray should not detect this object. simple regexp */
   }
   always_detect {
    /* overrides the never_detect settings. not really necessary to have but
could be convenient */
    c[rt]s /* any ray that was first from the camera, then either reflected
or transmitted, then testing for a shadow, should detect this object. */
   }
 }
}

By making characters represent different types of rays, we could use a
regular expression syntax to describe which rays should detect the object
and which shouldn't. Some convenient ray types could be:

c - ray just came from the camera
r - ray was just reflected
s - ray is looking for a shadow (will never be followed by any other type of
ray since all it's doing is detecting the presence of an object, and won't
recursively call for more rays)
t - ray just passed through a transparent surface
d - ray is testing nearby colors for radiosity
p - ray is a photon being shot

I'm sure there's more types that I'm not thinking of that could be
implemented.

Does this idea make sense to everyone? Am I clear enough?

Mainly I'm bringing this up because it seems like it could be very powerful.
The regular expression syntax could be simplified somehow to make it easier
for new users, perhaps. Does this seem *possible* to implement? Worthwhile?

I also bring it up because I may not have the ambition to actually implement
it, but perhaps there is someone else who is excited by the idea and might
want to implement it. I don't say this out of laziness, but for the good of
the community.

So... what are your thoughts?

 - Slime
[ http://www.slimeland.com/ ]


Post a reply to this message

From: Rafal 'Raf256' Maj
Subject: Re: no_image, no_shadow, no_reflection, no_etc...
Date: 25 Jul 2002 23:07:30
Message: <Xns9257338C63870raf256com@204.213.191.226>
"Slime" <slm### [at] slimelandcom> wrote in news:3d40950f@news.povray.org

Interesting idea IMHO :) but most peoples here doesn't like future-requests 
:-/ or just mine requests where too stupid ;) maybe at least someone will 
like my photons_power idea ? it's simple and gives nice results

-- 
#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

From: Le Forgeron
Subject: Re: no_image, no_shadow, no_reflection, no_etc...
Date: 31 Jul 2002 13:07:39
Message: <3D48194E.F106EE1@free.fr>
Slime wrote:
 
> Does this idea make sense to everyone? Am I clear enough?
>

I can understand it...
 
> Mainly I'm bringing this up because it seems like it could be very powerful.
> The regular expression syntax could be simplified somehow to make it easier
> for new users, perhaps. Does this seem *possible* to implement? Worthwhile?

Possible : probably with a little tracking of the succession of rays,
           problems I foresee might be the possible infinite length of the string
           and the infinite number of strings for one object (because a single regex
           is far too limited until you introduced the |.

Worthwhile: what is the current percentage of use of no_shadow / no_image /
no_reflection
?
            what would be the usage of such extension ?
            probably none, at least for most of the realistic render, and
            only causualy for very few thematic scenes.
        
> I also bring it up because I may not have the ambition to actually implement
> it, but perhaps there is someone else who is excited by the idea and might
> want to implement it. I don't say this out of laziness, but for the good of
> the community.

I'm not excited... at least not by that... :->

> So... what are your thoughts?

Read my previous answers (too much complexity for nothing).

-- 
Non Sine Numine
http://grimbert.cjb.net/
Etiquette is for those with no breeding;
fashion for those with no taste.


Post a reply to this message

From: Timothy R  Cook
Subject: Re: no_image, no_shadow, no_reflection, no_etc...
Date: 31 Jul 2002 14:12:21
Message: <3D482883.5010500@bellsouth.net>
I think the no_image keyword should do exactly that.
It would really speed up those complex scenes...;)

-- 
Tim Cook
http://empyrean.scifi-fantasy.com
mirror: http://personal.lig.bellsouth.net/lig/z/9/z993126

-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GFA dpu- s: a?-- C++(++++) U P? L E--- W++(+++)>$
N++ o? K- w(+) O? M-(--) V? PS+(+++) PE(--) Y(--)
PGP-(--) t* 5++>+++++ X+ R* tv+ b++(+++) DI
D++(---) G(++) e*>++ h+ !r--- !y--
------END GEEK CODE BLOCK------


Post a reply to this message

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