Ignore:
Timestamp:
02/08/07 15:46:23 (17 years ago)
Author:
bittner
Message:

simple ray separated

File:
1 edited

Legend:

Unmodified
Added
Removed
  • GTP/trunk/Lib/Vis/Preprocessing/src/Mutation.cpp

    r2076 r2105  
    625625        sray = SimpleRay(mRays[index].mutatedOrigin, 
    626626                                         Normalize(mRays[index].mutatedTermination - mRays[index].mutatedOrigin), 
    627                                          MUTATION_BASED_DISTRIBUTION, 1.0f); 
     627                                         MUTATION_BASED_DISTRIBUTION, 
     628                                         1.0f); 
     629         
     630         
    628631        sray.mGeneratorId = index; 
    629632        mRays[index].ResetReverseMutation(); 
     
    676679  // use probabilitistic approach to decide for the type of mutation 
    677680  float a = RandomValue(0.0f,1.0f); 
    678  
     681  bool bidirectional = true; 
     682   
    679683  if (mUseSilhouetteSamples && a < mSilhouetteProb) { 
     684         
    680685        termination += ComputeSilhouetteTerminationMutation(*ray, 
    681686                                                                                                                origin, 
     
    683688                                                                                                                U, V, 
    684689                                                                                                                2.0f*objectRadius); 
     690        bidirectional = false; 
    685691  } else { 
    686692        mRays[index].mHalton.GetNext(4, rr); 
     
    711717  sray = SimpleRay(origin, direction, MUTATION_BASED_DISTRIBUTION, pdf); 
    712718  sray.mGeneratorId = index; 
    713  
     719  sray.SetBidirectional(bidirectional); 
     720   
    714721  return true; 
    715722} 
Note: See TracChangeset for help on using the changeset viewer.