File tree Expand file tree Collapse file tree 3 files changed +3
-7
lines changed Expand file tree Collapse file tree 3 files changed +3
-7
lines changed Original file line number Diff line number Diff line change 3017
3017
3018
3018
// Move the intersection point forwards by the offset
3019
3019
rec.p += offset;
3020
- rec.set_face_normal(offset_r, rec.normal);
3021
3020
3022
3021
return true;
3023
3022
}
3050
3049
3051
3050
// Move the intersection point forwards by the offset
3052
3051
rec.p += offset;
3053
- rec.set_face_normal(offset_r, rec.normal);
3054
3052
3055
3053
return true;
3056
3054
}
3225
3223
normal[2] = -sin_theta*rec.normal[0] + cos_theta*rec.normal[2];
3226
3224
3227
3225
rec.p = p;
3228
- rec.set_face_normal(rotated_r, normal) ;
3226
+ rec.normal = normal;
3229
3227
3230
3228
return true;
3231
3229
}
Original file line number Diff line number Diff line change @@ -64,7 +64,6 @@ class translate : public hittable {
64
64
65
65
// Move the intersection point forwards by the offset
66
66
rec.p += offset;
67
- rec.set_face_normal (offset_r, rec.normal );
68
67
69
68
return true ;
70
69
}
@@ -140,7 +139,7 @@ class rotate_y : public hittable {
140
139
normal[2 ] = -sin_theta*rec.normal [0 ] + cos_theta*rec.normal [2 ];
141
140
142
141
rec.p = p;
143
- rec.set_face_normal (rotated_r, normal) ;
142
+ rec.normal = normal;
144
143
145
144
return true ;
146
145
}
Original file line number Diff line number Diff line change @@ -72,7 +72,6 @@ class translate : public hittable {
72
72
73
73
// Move the intersection point forwards by the offset
74
74
rec.p += offset;
75
- rec.set_face_normal (offset_r, rec.normal );
76
75
77
76
return true ;
78
77
}
@@ -148,7 +147,7 @@ class rotate_y : public hittable {
148
147
normal[2 ] = -sin_theta*rec.normal [0 ] + cos_theta*rec.normal [2 ];
149
148
150
149
rec.p = p;
151
- rec.set_face_normal (rotated_r, normal) ;
150
+ rec.normal = normal;
152
151
153
152
return true ;
154
153
}
You can’t perform that action at this time.
0 commit comments