Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8148781
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T14:42:48+00:00 2026-06-06T14:42:48+00:00

I have a quite strange issue. Please, look at these screenshots: Code of that

  • 0

I have a quite strange issue. Please, look at these screenshots:

img1

img2

img3

img4

Code of that object:

void prostopadloscian(float x, float y, float z, float red, float green, float blue)
{
    glBegin(GL_QUADS);
        glColor3f(red, green, blue);

        glNormal3f(-x,-y,-z);
        glVertex3f(-x,-y,-z);
        glNormal3f(x,-y,-z);
        glVertex3f(x,-y,-z);
        glNormal3f(x,-y,z);
        glVertex3f(x,-y,z);
        glNormal3f(-x,-y,z);
        glVertex3f(-x,-y,z);

        glNormal3f(-x,y,-z);
        glVertex3f(-x,y,-z);
        glNormal3f(x,y,-z);
        glVertex3f(x,y,-z);
        glNormal3f(x,y,z);
        glVertex3f(x,y,z);
        glNormal3f(-x,y,z);
        glVertex3f(-x,y,z);

        glNormal3f(-x,y,z);
        glVertex3f(-x,y,z);
        glNormal3f(-x,-y,z);
        glVertex3f(-x,-y,z);
        glNormal3f(-x,-y,-z);
        glVertex3f(-x,-y,-z);
        glNormal3f(-x,y,-z);
        glVertex3f(-x,y,-z);

        glNormal3f(-x,-y,-z);
        glVertex3f(-x,-y,-z);
        glNormal3f(x,-y,-z);
        glVertex3f(x,-y,-z);
        glNormal3f(x,y,-z);
        glVertex3f(x,y,-z);
        glNormal3f(-x,y,-z);
        glVertex3f(-x,y,-z);

        glNormal3f(x,y,z);
        glVertex3f(x,y,z);
        glNormal3f(x,-y,z);
        glVertex3f(x,-y,z);
        glNormal3f(x,-y,-z);
        glVertex3f(x,-y,-z);
        glNormal3f(x,y,-z);
        glVertex3f(x,y,-z);

        glNormal3f(-x,y,z);
        glVertex3f(-x,y,z);
        glNormal3f(-x,-y,z);
        glVertex3f(-x,-y,z);
        glNormal3f(-x,-y,-z);
        glVertex3f(-x,-y,-z);
        glNormal3f(-x,y,-z);
        glVertex3f(-x,y,-z);
    glEnd();
}
    void bed()
    {
        glPushMatrix();
            glTranslatef(-1.6, 0, 4.6);
            prostopadloscian(0.2, 0.25, 0.2, 0.35, 0.16, 0.14);
        glPopMatrix();
        glPushMatrix();
            glTranslatef(1.6, 0, 4.6);
            prostopadloscian(0.2, 0.25, 0.2, 0.35, 0.16, 0.14);
        glPopMatrix();
        glPushMatrix();
            glTranslatef(-1.6, 0, -4.6);
            prostopadloscian(0.2, 0.25, 0.2, 0.35, 0.16, 0.14);
        glPopMatrix();
        glPushMatrix();
            glTranslatef(1.6, 0, -4.6);
            prostopadloscian(0.2, 0.25, 0.2, 0.35, 0.16, 0.14);
        glPopMatrix();

        glPushMatrix();
            glTranslatef(0.0, 0.55, 0.0);
            prostopadloscian(2,0.3,5,0.85,0.85,0.95);
        glPopMatrix();
    }

my display() function starts at

glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
glClearColor(1.0, 1.0, 1.0, 1.0); 

glEnable(GL_DEPTH_TEST);
glDisable(GL_TEXTURE_2D);
glLoadIdentity();

How to get rid of this ugly effect?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-06T14:42:49+00:00Added an answer on June 6, 2026 at 2:42 pm

    Yeah, those prostopadloscians do look a bit strange. It’s hard to say for sure from these shots, but some things to look at:

    • Is backface culling enabled?
    • If so, are you specifying the vertices in the right order?
    • Are your front and back clipping plane not too far apart?
    • Does your depth buffer have enough bits for the clipping plane distance you’re using?
    • Are your normals all pointing the right way? (Hint: no. Unless you’re being tricky, each face should need only one glNormal call.)
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a strange issue from a client in that our code, which they
That's realy strange issue, i have quite a lot of plugins and custom scripts
I have just come across something that is quite strange and yet I haven't
I have a strange problem that I can't seem to solve. I've quite a
I have quite a complex piece of code (JQuery and HTML5 Web SQL) that
I'm having a bit of a strange issue that I can't quite figure out.
I've got a strange issue. This is suddenly started happening in the code that
I have quite a strange problem with PHP and Apache on my local testing
I have quite big document in html format that generated from Microsoft Word. It
I am facing quite a strange problem at the moment, I have wordpress and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.