POV-Ray : Newsgroups : povray.general : QUESTION: How to Emit Light? Server Time
25 Apr 2024 05:32:30 EDT (-0400)
  QUESTION: How to Emit Light? (Message 2 to 11 of 11)  
<<< Previous 1 Messages Goto Initial 10 Messages
From: clipka
Subject: Re: QUESTION: How to Emit Light?
Date: 2 Dec 2017 00:01:45
Message: <5a2233b9$1@news.povray.org>
Am 02.12.2017 um 05:24 schrieb Sven Littkowski:
> Please see the code below, and let me know, how I can make these rings
> illuminate their neighborhood?

What do you mean by "illuminate their neighborhood"? Do you want the
rings to cast light onto nearby objects, or do you want a glowing "halo"
around the rings?


Post a reply to this message

From: Sven Littkowski
Subject: Re: QUESTION: How to Emit Light?
Date: 2 Dec 2017 03:04:32
Message: <5a225e90$1@news.povray.org>
On 02.12.2017 00:01, clipka wrote:
> What do you mean by "illuminate their neighborhood"? Do you want the
> rings to cast light onto nearby objects, or do you want a glowing "halo"
> around the rings?

Hi, thanks for your time. :-)

I want to cast light onto nearby objects without having to use radiosity
(I get already a nice illumination with radiosity, but I like it without
radiosity, too, if possible), but I also want a glow around the objects.

---
Diese E-Mail wurde von AVG auf Viren geprüft.
http://www.avg.com


Post a reply to this message

From: clipka
Subject: Re: QUESTION: How to Emit Light?
Date: 2 Dec 2017 04:51:51
Message: <5a2277b7@news.povray.org>
Am 02.12.2017 um 09:04 schrieb Sven Littkowski:
> On 02.12.2017 00:01, clipka wrote:
>> What do you mean by "illuminate their neighborhood"? Do you want the
>> rings to cast light onto nearby objects, or do you want a glowing "halo"
>> around the rings?
> 
> Hi, thanks for your time. :-)
> 
> I want to cast light onto nearby objects without having to use radiosity
> (I get already a nice illumination with radiosity, but I like it without
> radiosity, too, if possible), but I also want a glow around the objects.

To cast light onto nearby objects, the only alternative to radiosity I'm
aware of would be fill lights (light sources with `shadowless`), but I'd
expect them to be difficult to set up for your use case (you don't want
the ring itself to be illuminated by the fill lights, for instance).

For the glow around the objects, you'll need emissive media.


Post a reply to this message

From: Stephen
Subject: Re: QUESTION: How to Emit Light?
Date: 2 Dec 2017 05:26:48
Message: <5a227fe8$1@news.povray.org>
On 02/12/2017 09:51, clipka wrote:
> Am 02.12.2017 um 09:04 schrieb Sven Littkowski:
>> On 02.12.2017 00:01, clipka wrote:
>>> What do you mean by "illuminate their neighborhood"? Do you want the
>>> rings to cast light onto nearby objects, or do you want a glowing "halo"
>>> around the rings?
>>
>> Hi, thanks for your time. :-)
>>
>> I want to cast light onto nearby objects without having to use radiosity
>> (I get already a nice illumination with radiosity, but I like it without
>> radiosity, too, if possible), but I also want a glow around the objects.
> 
> To cast light onto nearby objects, the only alternative to radiosity I'm
> aware of would be fill lights (light sources with `shadowless`), but I'd
> expect them to be difficult to set up for your use case (you don't want
> the ring itself to be illuminated by the fill lights, for instance).
> 

Would everything but the rings in a light group, work?


-- 

Regards
     Stephen


Post a reply to this message

From: Alain
Subject: Re: QUESTION: How to Emit Light?
Date: 2 Dec 2017 14:10:56
Message: <5a22fac0$1@news.povray.org>
Le 17-12-01 à 23:24, Sven Littkowski a écrit :
> Please see the code below, and let me know, how I can make these rings
> illuminate their neighborhood?
> 
> union
> {
>   torus { 2.475 0.025 rotate < 0.0, 0.0, 90.0 > translate < 20.0, 0.0,
> 0.0 > rotate < 0.0, 000.0, 0.0 > }
>   torus { 2.475 0.025 rotate < 0.0, 0.0, 90.0 > translate < 20.0, 0.0,
> 0.0 > rotate < 0.0, 120.0, 0.0 > }
>   torus { 2.475 0.025 rotate < 0.0, 0.0, 90.0 > translate < 20.0, 0.0,
> 0.0 > rotate < 0.0, 240.0, 0.0 > }
>   hollow
>   pigment { color rgb < 0.8784314,  0.2,  0.003921569 > }
>   interior
>   {
>    media
>    {
>     samples 20
> //   absorption < 3.0, 4.0, 0.5 >*1.0
>     emission   < 1.0, 1.0, 1.0 >*10.0
>     scattering
>     {
>      1
>      < 0.5, 0.75, 1.5 >*3.0
>      extinction 0.5
>     }
>    }
>   }
>   finish { emission 10.0  }
> }
> 
> ---
> Diese E-Mail wurde von AVG auf Viren geprüft.
> http://www.avg.com
> 

Your pigment is opaque, so, you never see the media.


If you only want the tori to illuminate the area, you need to use radiosity.
Can be turned on, using default parameters, by adding an empty radiosity 
block in the glabal_settings block:
glabal_settings{radiosity{}}

You parbably need to use beter parameters.
Start with count, something around 100 as a starter.
Reduce pretrace_end from default 0.04 to maybe 0.01.

With emission 10, you get an apparent yellow for the torus, but the 
illumination will be orange.

If you want some kind of aura around them, then you need to have a 
slightly larger torus around then that will be filled with some emissive 
media.


Post a reply to this message

From: Alain
Subject: Re: QUESTION: How to Emit Light?
Date: 2 Dec 2017 14:30:35
Message: <5a22ff5b$1@news.povray.org>
Le 17-12-02 à 03:04, Sven Littkowski a écrit :
> On 02.12.2017 00:01, clipka wrote:
>> What do you mean by "illuminate their neighborhood"? Do you want the
>> rings to cast light onto nearby objects, or do you want a glowing "halo"
>> around the rings?
> 
> Hi, thanks for your time. :-)
> 
> I want to cast light onto nearby objects without having to use radiosity
> (I get already a nice illumination with radiosity, but I like it without
> radiosity, too, if possible), but I also want a glow around the objects.
> 
> ---
> Diese E-Mail wurde von AVG auf Viren geprüft.
> http://www.avg.com
> 

Remove the interior as it's not needed.

Add "no_shadow" to your torus.
Place a few lights inside the torus along it's major radius.
Make sure that they are fading lights.

#declare Light_Torus = union{
  torus { 2.475 0.025 }
  #for(P, 0, 330, 30)//add 12 lights
   light_source{2.475*x, rgb < 0.8784314,  0.2,  0.003921569 >
    area_light 0*x, 0.3*z, 1, 5 adaptive 0
    fade_distance 0.3 fade_power 2
    rotate P*y
   }
  #end
  no_shadow
  torus { 2.475 0.065 hollow // For the glowing aura
   pigment{rgbt 1}
   media{ samples 5 // Enough for that simple media
    emission < 0.8784314,  0.2,  0.003921569 >*5
    }
  }
}

union{
  object{Light_Torus rotate 90*z }
  object{Light_Torus rotate 90*z rotate 120*y}
  object{Light_Torus rotate 90*z rotate 240*y}
  pigment { color rgb < 0.8784314,  0.2,  0.003921569 > }
  emission 10
}


Post a reply to this message

From: Sven Littkowski
Subject: Re: QUESTION: How to Emit Light?
Date: 2 Dec 2017 16:40:25
Message: <5a231dc9$1@news.povray.org>
On 02.12.2017 14:32, Alain wrote:
> Remove the interior as it's not needed.
> Add "no_shadow" to your torus.
> Place a few lights inside the torus along it's major radius.
> Make sure that they are fading lights.

Alain, thanks a lot for your advise.
I decided, to use radiosity.
But my question remains, how to create a glow-producing media in or
around the torus. I started already, but it does not produce the desired
glow effect.

---
Diese E-Mail wurde von AVG auf Viren geprüft.
http://www.avg.com


Post a reply to this message

From: Sven Littkowski
Subject: Re: QUESTION: How to Emit Light?
Date: 2 Dec 2017 16:54:12
Message: <5a232104$1@news.povray.org>
Thanks! If I understand correctly, the existing torus cannot be made
glowing (having an aura around it). I have to create a new torus
(thicker diameter), which then is filled with the glow, am I correct?

I will go ahead and create a new surrounding torus, and fill it with
media. Please see below and advise me (I do not have any experience with
media).
--------------------------

union
{
 union // original torus
 {
  torus { 2.475 0.025 rotate < 0.0, 0.0, 90.0 > translate < 20.0, 0.0,
0.0 > rotate < 0.0, 000.0, 0.0 > }
  torus { 2.475 0.025 rotate < 0.0, 0.0, 90.0 > translate < 20.0, 0.0,
0.0 > rotate < 0.0, 120.0, 0.0 > }
  torus { 2.475 0.025 rotate < 0.0, 0.0, 90.0 > translate < 20.0, 0.0,
0.0 > rotate < 0.0, 240.0, 0.0 > }
  pigment { color rgb < 0.8784314,  0.1,  0.003921569 > } // mandatory
orange
  finish { emission 30.0  }
 }
 union // larger glowing torus
 {
  torus { 2.475 0.150 rotate < 0.0, 0.0, 90.0 > translate < 20.0, 0.0,
0.0 > rotate < 0.0, 000.0, 0.0 > }
  torus { 2.475 0.150 rotate < 0.0, 0.0, 90.0 > translate < 20.0, 0.0,
0.0 > rotate < 0.0, 120.0, 0.0 > }
  torus { 2.475 0.150 rotate < 0.0, 0.0, 90.0 > translate < 20.0, 0.0,
0.0 > rotate < 0.0, 240.0, 0.0 > }
  hollow
  pigment { color rgb < 0.8784314,  0.1,  0.003921569 > } // mandatory
orange
  finish { emission 30.0  }
  interior
  {
   media
   {
    samples 100
//    absorption < 3.0, 4.0, 0.5 >*1.0
    emission   < 1.0, 1.0, 1.0 >*10.0
    scattering
    {
     1
     < 0.5, 0.75, 1.5 >*3.0
     extinction 0.5
    }
   }
  }
 }
}


---
Diese E-Mail wurde von AVG auf Viren geprüft.
http://www.avg.com


Post a reply to this message

From: Bald Eagle
Subject: Re: QUESTION: How to Emit Light?
Date: 2 Dec 2017 17:10:01
Message: <web.5a2323d429de4f055cafe28e0@news.povray.org>
Take a look at some of what went on in recent threads:

http://news.povray.org/povray.general/thread/%3Cweb.59f243919b56bbddbb23337d0%40news.povray.org%3E/

http://news.povray.org/povray.binaries.images/thread/%3Cweb.59fa2a48231a9fe3ec54f04a0%40news.povray.org%3E/


Post a reply to this message

From: Alain
Subject: Re: QUESTION: How to Emit Light?
Date: 2 Dec 2017 18:18:34
Message: <5a2334ca$1@news.povray.org>
Le 17-12-02 à 16:40, Sven Littkowski a écrit :
> On 02.12.2017 14:32, Alain wrote:
>> Remove the interior as it's not needed.
>> Add "no_shadow" to your torus.
>> Place a few lights inside the torus along it's major radius.
>> Make sure that they are fading lights.
> 
> Alain, thanks a lot for your advise.
> I decided, to use radiosity.
> But my question remains, how to create a glow-producing media in or
> around the torus. I started already, but it does not produce the desired
> glow effect.
> 
> ---
> Diese E-Mail wurde von AVG auf Viren geprüft.
> http://www.avg.com
> 

You place a second fully transparent torus with a larger minor radius 
around the main torus. You make that torus hollow and fill it with some 
emissive media.
That media, by default, will have an uniform density.

If you want to have non-uniform density, and as there is no toric 
pattern, you'll need to provide a function to controll the density.

You can use functions.inc and f_torus/f_torus2 as a good start point.
f_torus(x,y,z, Major_Radius, Minor_Radius)
or
f_torus2(x,y,z, Field_Strength, Major_Radius, Minor_Radius)
(the sample scene i_internal.pov show some examples of the uses of those 
functions)

Those evaluate as zero on the minor radius and increase as you get 
farther away.

Sample :
   #declare LCorner = <-1, -0.25, -1>;
   #declare RCorner = <1, 0.25, 1>;
	isosurface {
		function { f_torus(x,y,z, 0.8, 0.2) }
			//P0= major radius
			//P1= minor radius
		contained_by { box { LCorner, RCorner } }
		max_gradient 1
		texture { rgbt 1 }
		hollow
   interior{
     media{emission rgb 1
        density{f_torus(x,y,z, 0.8, 0) }
        }
   rotate -30*x		
	}

When used in a pigment or to controll the density of a media, the minor 
radius set the radius where the entry 0 of a colour_map or density map 
is located.

Here's a small test scene to get you started :
   #version 3.7;
   global_settings{assumed_gamma 1}

   #include "functions.inc"
union{
	torus{1, 0.3 pigment{rgb 0.3}}//Parent
	torus{1, 1	//container
		hollow
   interior{
     media{emission rgb 1
     	samples 20
        density{function{f_torus(x,y,z, 1, 0.3) }
//The major and minor radius must match those of the parent torus
        density_map{[0 rgb<1,0,0>][0.1 rgb 1][0.2 rgb 0.2][0.7 rgb 0]}
        turbulence 0.1}
        }
     }
	}
	pigment{rgbt 1}

	rotate -25*x
	translate 5*z
	}


Post a reply to this message

<<< Previous 1 Messages Goto Initial 10 Messages

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