tmp restore a 3d view
This commit is contained in:
@@ -43,7 +43,7 @@ static void wall_length(t_rcast *rcast)
|
||||
if (rcast->slope_y)
|
||||
len /= ft_abs(rcast->slope_y);
|
||||
// len = (double)len * (double)rcast->screen_dist.end.y / (double)rcast->slope_x;
|
||||
// len = rcast->screen_dist * len / (rcast->slope_x);
|
||||
len = rcast->screen_dist * len / (rcast->slope_x);
|
||||
}
|
||||
else if (rcast->is_x == 0)
|
||||
{
|
||||
@@ -51,7 +51,7 @@ static void wall_length(t_rcast *rcast)
|
||||
if (rcast->slope_x)
|
||||
len /= ft_abs(rcast->slope_x);
|
||||
// len = (double)len * (double)rcast->screen_dist.end.y / (double)rcast->slope_y;
|
||||
// len = rcast->screen_dist * len / (rcast->slope_y);
|
||||
len = rcast->screen_dist * len / (rcast->slope_y);
|
||||
}
|
||||
rcast->ray_len = ft_abs(len);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user