void criarNovoPonto(){
     points->at(0).setColor(Color(0,0,0,1));
     points->at(1).setColor(Color(0,0,0,1));
     
     
     // Now find the intersection point;
     // use formulas y = y0 + slope * (x - x0), x = x0 + (1 / slope) * (y - y0)
     if (outcodeOut & TOP) {           // point is above the clip rectangle
         x = x0 + (x1 - x0) * (yMax - y0) / (y1 - y0);
         y = yMax;
     } else if (outcodeOut & BOTTOM) { // point is below the clip rectangle
         x = x0 + (x1 - x0) * (yMin - y0) / (y1 - y0);
         y = yMin;
     } else if (outcodeOut & RIGHT) {  // point is to the right of clip rectangle
         y = y0 + (y1 - y0) * (xMax - x0) / (x1 - x0);
         x = xMax;
     } else if (outcodeOut & LEFT) {   // point is to the left of clip rectangle
         y = y0 + (y1 - y0) * (xMin - x0) / (x1 - x0);
         x = xMin;
     }
     
     printf("Novo ponto calculado: (%lf, %lf)\n",x,y);
     
     Point2D point = Point2D(x, y);
     point.setColor(Color(1,0,0,1));
     points->push_back(point);
     
     step++;
 }