#include <GL/glut.h>
#include <stdio.h>
#include <cstdlib>
#include <windows.h>
void dda_line(int x1, int y1, int x2, int y2) {
glPointSize(1.0);
glBegin(GL_POINTS);
glVertex2i(x1, y1);
glVertex2i(x2, y2);
// x,y的增量
int dx = x2 - x1;
int dy = y2 - y1;
double dert_x;
double dert_y;
double x, y;
int