Ignore:
Timestamp:
11/28/06 19:46:36 (18 years ago)
Author:
bittner
Message:

global lines support

File:
1 edited

Legend:

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

    r1786 r1824  
    2323        if (ray.GetType() == Ray::LOCAL_RAY && !ray.intersections.empty()) 
    2424                nearestT = ray.intersections[0].mT; 
    25  
     25         
    2626        const int hitCode = mItem.CastRay(ray, t, nearestT, nearestNormal); 
    2727 
    2828        nearestT = t; 
    2929 
    30         if ((hitCode == Ray::INTERSECTION) && (ray.GetType() == Ray::LOCAL_RAY)) 
    31         { 
    32                 if (!ray.intersections.empty()) 
    33                 { 
    34                         ray.intersections[0] = Ray::Intersection(nearestT, nearestNormal, this, 0); 
     30        if (hitCode == Ray::INTERSECTION) { 
     31                if (ray.GetType() == Ray::LOCAL_RAY && !ray.intersections.empty()) { 
     32                        ray.intersections[0] = Ray::Intersection(nearestT, 
     33                                                                                                                                                                                         nearestNormal, 
     34                                                                                                                                                                                         this, 
     35                                                                                                                                                                                         0); 
    3536                } 
    36                 else 
    37                 { 
    38                         ray.intersections.push_back(Ray::Intersection(nearestT, nearestNormal, this, 0)); 
     37                else { 
     38                        ray.intersections.push_back(Ray::Intersection(nearestT, 
     39                                                                                                                                                                                                                nearestNormal, 
     40                                                                                                                                                                                                                this, 
     41                                                                                                                                                                                                                0)); 
    3942                } 
    4043                 
    4144                return 1; 
    4245        } 
    43  
     46         
    4447        return 0; 
    4548} 
Note: See TracChangeset for help on using the changeset viewer.