POV-Ray : Newsgroups : povray.advanced-users : Speeding up media : Re: Speeding up media Server Time
19 Apr 2024 01:50:07 EDT (-0400)
  Re: Speeding up media  
From: William F Pokorny
Date: 13 Feb 2021 19:36:19
Message: <60287083$1@news.povray.org>
On 2/13/21 8:18 AM, Ash Holsenback wrote:
> On 2/13/21 2:35 AM, Thomas de Groot wrote:
...
> 
> spotted another difference with default for aa_level... 2nd paragraph 
> after 1st note has it at 4
> 
> while: http://wiki.povray.org/content/Reference:Media
> 
> has it at 3... inquiring minds wanna know
> 

It looks like it is 3.

media.cpp has:

Media::Media()
{
     Type = ISOTROPIC_SCATTERING;

     Intervals      = 10;
     Min_Samples    = 1;
     Max_Samples    = 1;
     Eccentricity   = 0.0;

     Absorption.Clear();
     Emission.Clear();
     Extinction.Clear();
     Scattering.Clear();

     is_constant = false;

     use_absorption = false;
     use_emission   = false;
     use_extinction = false;
     use_scattering = false;

     ignore_photons = false;

     sc_ext     = 1.0;
     Ratio      = 0.9;
     Confidence = 0.9;
     Variance   = 1.0 / 128.0;

     Sample_Threshold = nullptr;

     Sample_Method = 1;
     AA_Threshold = 0.1;
     AA_Level = 3;
     Jitter = 0.0;
}

Before anyone jumps on the Intervals, Min_Samples, Max_Samples and 
Sample_Method defaults above, in parser_materials.cpp we have:

     if (AllowToken(MEDIA_ID_TOKEN))
         IMediaObj = CurrentTokenData<Media>();
     else
     {
         /* as of v3.5, the default media method is now 3 */
         if (sceneData->EffectiveLanguageVersion() >= 350)
         {
             IMedia->Intervals = 1;
             IMedia->Min_Samples = 10;
             IMedia->Max_Samples = 10;
             IMedia->Sample_Method = 3;
         }
     }

---
Won't that parser override sometimes mess up the defaults for method 1 
and 2 you ask. Yes, I think it well might... I'm not going to do the 
work to prove it now, but likely media 1 & 2 users will 'always' have to 
set the intervals to 10, min and max to 1 if they want documented 
defaults for those two methods.

Bill P.


Post a reply to this message

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