mirror of
https://github.com/overte-org/overte.git
synced 2025-04-25 14:33:31 +02:00
Marker lines all the way out to 128Meters
This commit is contained in:
parent
b9a8d6080e
commit
8aa8b5dbfe
2 changed files with 25 additions and 10 deletions
|
@ -857,7 +857,7 @@ void Application::mouseMoveEvent(QMouseEvent* event) {
|
|||
|
||||
const bool MAKE_SOUND_ON_VOXEL_HOVER = false;
|
||||
const bool MAKE_SOUND_ON_VOXEL_CLICK = true;
|
||||
const float HOVER_VOXEL_FREQUENCY = 14080.f;
|
||||
const float HOVER_VOXEL_FREQUENCY = 7040.f;
|
||||
const float HOVER_VOXEL_DECAY = 0.999f;
|
||||
|
||||
void Application::mousePressEvent(QMouseEvent* event) {
|
||||
|
|
|
@ -224,38 +224,53 @@ void noiseTest(int w, int h) {
|
|||
}
|
||||
|
||||
void renderWorldBox() {
|
||||
// Show edge of world
|
||||
// Show edge of world
|
||||
float red[] = {1, 0, 0};
|
||||
float green[] = {0, 1, 0};
|
||||
float blue[] = {0, 0, 1};
|
||||
float gray[] = {0.5, 0.5, 0.5};
|
||||
|
||||
glDisable(GL_LIGHTING);
|
||||
glColor4f(1.0, 1.0, 1.0, 1.0);
|
||||
glLineWidth(1.0);
|
||||
glBegin(GL_LINES);
|
||||
glColor3f(1, 0, 0);
|
||||
glColor3fv(red);
|
||||
glVertex3f(0, 0, 0);
|
||||
glVertex3f(TREE_SCALE, 0, 0);
|
||||
glColor3f(0, 1, 0);
|
||||
glColor3fv(green);
|
||||
glVertex3f(0, 0, 0);
|
||||
glVertex3f(0, TREE_SCALE, 0);
|
||||
glColor3f(0, 0, 1);
|
||||
glColor3fv(blue);
|
||||
glVertex3f(0, 0, 0);
|
||||
glVertex3f(0, 0, TREE_SCALE);
|
||||
glColor3fv(gray);
|
||||
glVertex3f(0, 0, TREE_SCALE);
|
||||
glVertex3f(TREE_SCALE, 0, TREE_SCALE);
|
||||
glVertex3f(TREE_SCALE, 0, TREE_SCALE);
|
||||
glVertex3f(TREE_SCALE, 0, 0);
|
||||
glEnd();
|
||||
// Draw little marker dots along the axis
|
||||
// Draw marker dots at very end
|
||||
glEnable(GL_LIGHTING);
|
||||
glPushMatrix();
|
||||
glTranslatef(TREE_SCALE, 0, 0);
|
||||
glColor3f(1, 0, 0);
|
||||
glColor3fv(red);
|
||||
glutSolidSphere(0.125, 10, 10);
|
||||
glPopMatrix();
|
||||
glPushMatrix();
|
||||
glTranslatef(0, TREE_SCALE, 0);
|
||||
glColor3f(0, 1, 0);
|
||||
glColor3fv(green);
|
||||
glutSolidSphere(0.125, 10, 10);
|
||||
glPopMatrix();
|
||||
glPushMatrix();
|
||||
glTranslatef(0, 0, TREE_SCALE);
|
||||
glColor3f(0, 0, 1);
|
||||
glColor3fv(blue);
|
||||
glutSolidSphere(0.125, 10, 10);
|
||||
glPopMatrix();
|
||||
glPushMatrix();
|
||||
glColor3fv(gray);
|
||||
glTranslatef(TREE_SCALE, 0, TREE_SCALE);
|
||||
glutSolidSphere(0.125, 10, 10);
|
||||
glPopMatrix();
|
||||
|
||||
}
|
||||
|
||||
double diffclock(timeval *clock1,timeval *clock2)
|
||||
|
|
Loading…
Reference in a new issue