チャンキング システムを使用してブロック ワールドに取り組んでいたときに、VBO のバグに遭遇しました。私の立方体の世界はランダムな頂点を生成するようですが、Radeon HD 6670 でのみ発生します。これは私のコード、LWJGL、OpenGL、6670、またはそのドライバーのバグによるものなのか、自分で修正できるものなのか疑問に思っています。 . スクリーンショットがいくつかありますが、どれも正しく機能していません。NVidia カードを搭載したラップトップでテストしたところ、まったく問題なく動作しました。現在、Intel HD 3000 でテストしようとしています。何が間違っているのか教えてもらえますか? 16 * 16 * 16 の立方体グリッドをカバーする正方形の面を生成することになっています。
編集: HD 3000 でも動作しないようですが、Nvidia カードでは問題なく動作します。
スクリーンショットは次のとおりです。http://imgur.com/a/Q30Y3
VBO を作成してレンダリングするコードは次のとおりです。
private void updateChunkVertexArray()
{
    thisVertices.clear();
    GL15.glDeleteBuffers(thisVBOID);
    GL15.glDeleteBuffers(thisTexID);
    FloatBuffer bufferedTex = BufferUtils
            .createFloatBuffer(buffer.size() * 8 * 6);
    thisTexID = VBOHandler.createVBO();
    thisVBOID = VBOHandler.createVBO();
    for (int i = 0; i < buffer.size(); i++)
    {
        Vector4f thisVec = buffer.get(i);
        float x = (thisVec.getX() + offsetX);
        float y = (thisVec.getY() + offsetY);
        float z = (thisVec.getZ() + offsetZ);
        float posx = 1.0f * size + x * 0.25f;
        float posy = 1.0f * size + y * 0.25f;
        float posz = 1.0f * size + z * 0.25f;
        float negx = -1.0f * size + x * 0.25f;
        float negy = -1.0f * size + y * 0.25f;
        float negz = -1.0f * size + z * 0.25f;
        if (world.getBlock(x, y, z + 1f) == 0)
        {
            bufferedTex.put(texCoords);
            float[ ] frontFace =
            {
                    // Front Face
                    negx, negy, posz, // Bottom Left
                    posx, negy, posz, // Bottom Right
                    posx, posy, posz, // Top Right Of
                    negx, posy, posz
            };
            for (int t = 0; t < frontFace.length; t++)
            {
                thisVertices.add(Float.valueOf(frontFace[t]));
            }
            //bufferedVertices.put(frontFace);
        }
        if (world.getBlock(x, y, z - 1f) == 0)
        {
            bufferedTex.put(texCoords);
            float[ ] backFace =
            {
                    // Back Face
                    negx, negy, negz, // Bottom Left
                    negx, posy, negz, // Bottom Right
                    posx, posy, negz, // Top Right Of
                    posx, negy, negz
            };
            for (int t = 0; t < backFace.length; t++)
            {
                thisVertices.add(Float.valueOf(backFace[t]));
            }
            //bufferedVertices.put(backFace);
        }
        if (world.getBlock(x, y + 1f, z) == 0)
        {
            bufferedTex.put(texCoords);
            float[ ] topFace =
            {
                    // Top Face
                    negx, posy, negz, // Bottom Left
                    negx, posy, posz, // Bottom Right
                    posx, posy, posz, // Top Right Of
                    posx, posy, negz
            };
            for (int t = 0; t < topFace.length; t++)
            {
                thisVertices.add(Float.valueOf(topFace[t]));
            }
            //bufferedVertices.put(topFace);
        }
        if (world.getBlock(x, y - 1f, z) == 0)
        {
            bufferedTex.put(texCoords);
            float[ ] bottomFace =
            {
                    // Bottom Face
                    negx, negy, negz, // Bottom Left
                    posx, negy, negz, // Bottom Right
                    posx, negy, posz, // Top Right Of
                    negx, negy, posz
            };
            for (int t = 0; t < bottomFace.length; t++)
            {
                thisVertices.add(Float.valueOf(bottomFace[t]));
            }
            //bufferedVertices.put(bottomFace);
        }
        if (world.getBlock(x + 1f, y, z) == 0)
        {
            bufferedTex.put(texCoords);
            float[ ] rightFace =
            {
                    // right Face
                    posx, negy, negz, // Bottom Left
                    posx, posy, negz, // Bottom Right
                    posx, posy, posz, // Top Right Of
                    posx, negy, posz
            };
            for (int t = 0; t < rightFace.length; t++)
            {
                thisVertices.add(Float.valueOf(rightFace[t]));
            }
            //bufferedVertices.put(rightFace);
        }
        if (world.getBlock(x - 1f, y, z) == 0)
        {
            bufferedTex.put(texCoords);
            float[ ] leftFace =
            {
                    // left Face
                    negx, negy, negz, // Bottom Left
                    negx, negy, posz, // Bottom Right
                    negx, posy, posz, // Top Right Of
                    negx, posy, negz
            };
            for (int t = 0; t < leftFace.length; t++)
            {
                thisVertices.add(Float.valueOf(leftFace[t]));
            }
            //bufferedVertices.put(leftFace);
        }
    }
    float[ ] tempVertices = new float[thisVertices.size()];
    for (int i = 0; i < thisVertices.size(); i++)
    {
        Float f = thisVertices.get(i);
        tempVertices[i] = Float.valueOf(f);
    }
    FloatBuffer bufferedVertices = BufferUtils
            .createFloatBuffer(thisVertices.size());
    bufferedVertices.put(tempVertices);
    bufferedVertices.flip();
    bufferedTex.flip();
    VBOHandler.bufferData(thisVBOID, bufferedVertices);
    VBOHandler.bufferData(thisTexID, bufferedTex);
//And now the rendering code...
public void renderChunk()
{
    //GL11.glCallList(chunkDisplayList);
    GL11.glEnableClientState(GL11.GL_VERTEX_ARRAY);
    GL15.glBindBuffer(GL15.GL_ARRAY_BUFFER, thisVBOID);
    GL11.glVertexPointer(3, GL11.GL_FLOAT, 0, 0);
    GL11.glEnableClientState(GL11.GL_TEXTURE_COORD_ARRAY);
    GL15.glBindBuffer(GL15.GL_ARRAY_BUFFER, thisTexID);
    GL11.glTexCoordPointer(2, GL11.GL_FLOAT, 0, 0);
    GL11.glDrawArrays(GL11.GL_QUADS, 0, thisVertices.size());
    GL11.glDisableClientState(GL11.GL_VERTEX_ARRAY); // deactivate vertex array
    GL11.glDisableClientState(GL11.GL_TEXTURE_COORD_ARRAY);
    // bind with 0 for normal pointers
    GL15.glBindBuffer(GL15.GL_ARRAY_BUFFER, 0);
    GL15.glBindBuffer(GL15.GL_ELEMENT_ARRAY_BUFFER, 0);
}