first commit

This commit is contained in:
Jose Caban
2025-06-07 01:59:34 -04:00
commit 388ac241f0
3558 changed files with 9116289 additions and 0 deletions

38
CS4451/proj1/ray.cpp Normal file
View File

@@ -0,0 +1,38 @@
#include <math.h>
#include <ostream>
#include <stdlib.h>
#include <vector>
#include "defs.h"
#include "functions.h"
Ray::Ray (Point start, Point end) {
this->direction = (end-start);
this->origin = end;
}
Ray Ray::operator+(Ray &other) {
Ray r;
r.direction = direction + other.direction;
r.origin = origin + other.origin;
return r;
}
Ray Ray::operator-(Ray &other) {
Ray r;
r.direction = direction - other.direction;
r.origin = origin - other.origin;
return r;
}