[LWJGL] Crash upon following SHC's LWJGL tutorial on Rotating Cube.

I am following this tutorial here.

Just when I start running my program, I encountered a crash. It gives me a crash log that I can’t seem to comprehend. Here’s the crash log:


#
# A fatal error has been detected by the Java Runtime Environment:
#
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000000005ff7c650, pid=6840, tid=4324
#
# JRE version: Java(TM) SE Runtime Environment (7.0_40-b43) (build 1.7.0_40-b43)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (24.0-b56 mixed mode windows-amd64 compressed oops)
# Problematic frame:
# C  [nvoglv64.DLL+0x98c650]
#
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
#
# An error report file with more information is saved as:
# C:\Users\Student\Documents\Workspace\LWJGL\hs_err_pid6840.log
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.sun.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#


Here’s my code:


//Something class.
package core;

import static org.lwjgl.opengl.GL11.*;
import static org.lwjgl.opengl.GL15.GL_ARRAY_BUFFER;
import static org.lwjgl.opengl.GL15.glBindBuffer;
import static org.lwjgl.util.glu.GLU.gluPerspective;
import game.Game;

import org.lwjgl.util.vector.Matrix4f;

public class Something {
	
	Cube cube;

	public Something() {
		this.cube = new Cube();
		glClearColor(0.4f, 0.8f, 0.95f, 1f);
	}
	
	public void render() {
		glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
		glMatrixMode(GL_PROJECTION);
		gluPerspective(70f, (float) Game.HEIGHT / (float) Game.WIDTH, 1f, 10f);
		glViewport(0, 0, Game.WIDTH, Game.HEIGHT);
		
		glMatrixMode(GL_MATRIX_MODE);
		glLoadIdentity();
		
		glEnable(GL_DEPTH_TEST);
		glEnableClientState(GL_VERTEX_ARRAY);
		glEnableClientState(GL_COLOR_ARRAY);
		
		glPushMatrix();
		glTranslatef(0f, 0f, -2f);
		glRotatef(1f, 1f, 1f, 0f);
		
		glBindBuffer(GL_ARRAY_BUFFER, cube.vboVertex);
		glVertexPointer(3, GL_FLOAT, 0, 0L);
		glBindBuffer(GL_ARRAY_BUFFER, cube.vboColor);
		glVertexPointer(3, GL_FLOAT, 0, 0L);
		
		glDrawArrays(GL_TRIANGLE_STRIP, 0, 24);
		glPopMatrix();
	}
	
}


//-----------------------------------------------------------------------------------------------------

//Cube class.
package core;

import static org.lwjgl.opengl.GL15.*;

import java.nio.FloatBuffer;

import org.lwjgl.BufferUtils;

public class Cube {
	private FloatBuffer vertexBuffer;
	private FloatBuffer colorBuffer;
	private float[] vertexData = new float[]
	{
			// Front face
			-0.5f, +0.5f, +0.5f,
			+0.5f, +0.5f, +0.5f,
			-0.5f, -0.5f, +0.5f,
			+0.5f, -0.5f, +0.5f,
			
			// Right face
			+0.5f, +0.5f, +0.5f,
			+0.5f, +0.5f, -0.5f,
			+0.5f, -0.5f, +0.5f,
			+0.5f, -0.5f, -0.5f,
			
			// Back face
			+0.5f, +0.5f, -0.5f,
			-0.5f, +0.5f, -0.5f,
			+0.5f, -0.5f, -0.5f,
			-0.5f, -0.5f, -0.5f,
			
			// Left face
			-0.5f, +0.5f, -0.5f,
			-0.5f, +0.5f, +0.5f,
			-0.5f, -0.5f, -0.5f,
			-0.5f, -0.5f, +0.5f,
			
			// Top face
			-0.5f, +0.5f, +0.5f,
			+0.5f, +0.5f, +0.5f,
			-0.5f, +0.5f, -0.5f,
			+0.5f, +0.5f, -0.5f,
			
			// Bottom face
			-0.5f, -0.5f, +0.5f,
			+0.5f, -0.5f, +0.5f,
			-0.5f, -0.5f, -0.5f,
			+0.5f, -0.5f, -0.5f
	};
	private float[] colorData = new float[]
	{
			// Front face
			1, 0, 0,
			0, 1, 0,
			0, 0, 1,
			1, 0, 0,
			
			// Right face
			0, 1, 0,
			0, 0, 1,
			1, 0, 0,
			0, 1, 0,
			
			// Back face
			0, 0, 1,
			1, 0, 0,
			0, 1, 0,
			0, 0, 1,
			
			// Left face
			1, 0, 0,
			0, 1, 0,
			0, 0, 1,
			1, 0, 0,
			
			// Top face
			0, 1, 0,
			0, 0, 1,
			1, 0, 0,
			0, 1, 0,
			
			// Bottom face
			0, 0, 1,
			1, 0, 0,
			0, 1, 0,
			0, 0, 1
	};
	
	public int vboVertex;
	public int vboColor;

	public Cube() {
		vertexBuffer = BufferUtils.createFloatBuffer(vertexData.length).put(vertexData);
		vertexBuffer.rewind();
		colorBuffer = BufferUtils.createFloatBuffer(colorData.length).put(colorData);
		colorBuffer.rewind();
		vboVertex = glGenBuffers();
		glBindBuffer(GL_ARRAY_BUFFER, vboVertex);
		glBufferData(GL_ARRAY_BUFFER, vertexBuffer, vboVertex);
		glBindBuffer(GL_ARRAY_BUFFER, 0);
		vboColor = glGenBuffers();
		glBindBuffer(GL_ARRAY_BUFFER, vboColor);
		glBufferData(GL_ARRAY_BUFFER, colorBuffer, vboColor);
		glBindBuffer(GL_ARRAY_BUFFER, 0);
	}
}



Any ideas what I’m doing wrong? Need more info?

Here, on line 27 in your above posted code, you have


glMatrixMode(GL_MATRIX_MODE);

Whereas you are supposed to have


glMatrixMode(GL_MODELVIEW);

Hope this helps.

Ah! That fixes the crash error. Sorry about that. :stuck_out_tongue:

After changing the value, I get nothing shown in the screen. :’( No cube! :’(

Anyway, thanks for the solution.

You must not be checking for OpenGl errors if you missed the above bug. Try that and see what happens.

So, just before I check on OpenGL errors, it now gives me another new error log dump, triggered by the method, “glDrawArrays(GL_TRIANGLE_FAN, 0, 24)”.

Note that I haven’t changed the code at all. I find it unusual that it worked yesterday, and now it’s not.


#
# A fatal error has been detected by the Java Runtime Environment:
#
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000000005ff7c650, pid=6840, tid=4324
#
# JRE version: Java(TM) SE Runtime Environment (7.0_40-b43) (build 1.7.0_40-b43)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (24.0-b56 mixed mode windows-amd64 compressed oops)
# Problematic frame:
# C  [nvoglv64.DLL+0x98c650]
#
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
#
# If you would like to submit a bug report, please visit:
#   http://bugreport.sun.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the bug.
#

---------------  T H R E A D  ---------------

Current thread (0x000000000cabe800):  JavaThread "Thread-0" [_thread_in_native, id=4324, stack(0x000000000c340000,0x000000000c440000)]

siginfo: ExceptionCode=0xc0000005, reading address 0x0000000000000000

Registers:
RAX=0x0000000000000006, RBX=0x000000000dddd3d8, RCX=0x0000000000000000, RDX=0x000000000d4d07a0
RSP=0x000000000c43e928, RBP=0x0000000000000018, RSI=0x000000000d4d06f0, RDI=0x0000000000000000
R8 =0xfffffffff2222c28, R9 =0x000000000dddd3d8, R10=0x000000005f5f0000, R11=0x000000000c43e980
R12=0x0000000000000000, R13=0x0000000000000005, R14=0x0000000000000000, R15=0x000000000cabe800
RIP=0x000000005ff7c650, EFLAGS=0x0000000000010297

Top of Stack: (sp=0x000000000c43e928)
0x000000000c43e928:   000000005ff7c09f 0000000bfbbf2f2a
0x000000000c43e938:   0000000061ccc49f 000000000cc48471
0x000000000c43e948:   00000000000000a6 0000000000000000
0x000000000c43e958:   000000005ff7b4cc 000000000d4d0080
0x000000000c43e968:   0000000000000018 0000000000000010
0x000000000c43e978:   0000000000000000 0000000000000003
0x000000000c43e988:   0000000200000000 0000000000000000
0x000000000c43e998:   0000000000000008 0000000000000000
0x000000000c43e9a8:   0000000000000000 0000000000000000
0x000000000c43e9b8:   0000000100000000 0000000400000002
0x000000000c43e9c8:   0000001000000008 0000004000000020
0x000000000c43e9d8:   0000010000000080 0000040000000200
0x000000000c43e9e8:   0000100000000800 0000400000002000
0x000000000c43e9f8:   0000000000008000 0000000000000000
0x000000000c43ea08:   0000140600000003 0000000000000010
0x000000000c43ea18:   0000000000000000 0000140600000003 

Instructions: (pc=0x000000005ff7c650)
0x000000005ff7c630:   43 0f b6 04 01 ff c1 4d 8d 49 01 41 88 41 ff 3b
0x000000005ff7c640:   4a 08 7c ec c3 33 c9 39 4a 08 7e 67 4d 2b c1 90
0x000000005ff7c650:   43 8b 04 01 ff c1 4d 8d 49 04 41 89 41 fc 3b 4a
0x000000005ff7c660:   08 7c ed c3 3d 0e 14 00 00 72 48 3d 0f 14 00 00 


Register to memory mapping:

RAX=0x0000000000000006 is an unknown value
RBX=0x000000000dddd3d8 is an unknown value
RCX=0x0000000000000000 is an unknown value
RDX=0x000000000d4d07a0 is an unknown value
RSP=0x000000000c43e928 is pointing into the stack for thread: 0x000000000cabe800
RBP=0x0000000000000018 is an unknown value
RSI=0x000000000d4d06f0 is an unknown value
RDI=0x0000000000000000 is an unknown value
R8 =0xfffffffff2222c28 is an unknown value
R9 =0x000000000dddd3d8 is an unknown value
R10=0x000000005f5f0000 is an unknown value
R11=0x000000000c43e980 is pointing into the stack for thread: 0x000000000cabe800
R12=0x0000000000000000 is an unknown value
R13=0x0000000000000005 is an unknown value
R14=0x0000000000000000 is an unknown value
R15=0x000000000cabe800 is a thread


Stack: [0x000000000c340000,0x000000000c440000],  sp=0x000000000c43e928,  free space=1018k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
C  [nvoglv64.DLL+0x98c650]

[error occurred during error reporting (printing native stack), id 0xc0000005]

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j  org.lwjgl.opengl.GL11.nglDrawArrays(IIIJ)V+0
j  org.lwjgl.opengl.GL11.glDrawArrays(III)V+20
j  core.Something.render()V+121
j  game.Game.render()V+4
j  game.Game.run()V+46
j  java.lang.Thread.run()V+11
v  ~StubRoutines::call_stub

---------------  P R O C E S S  ---------------

Java Threads: ( => current thread )
  0x000000000240e000 JavaThread "DestroyJavaVM" [_thread_blocked, id=3104, stack(0x0000000002570000,0x0000000002670000)]
=>0x000000000cabe800 JavaThread "Thread-0" [_thread_in_native, id=4324, stack(0x000000000c340000,0x000000000c440000)]
  0x000000000a911000 JavaThread "Service Thread" daemon [_thread_blocked, id=6028, stack(0x000000000c7f0000,0x000000000c8f0000)]
  0x000000000a90c800 JavaThread "C2 CompilerThread1" daemon [_thread_blocked, id=7124, stack(0x000000000c5e0000,0x000000000c6e0000)]
  0x000000000a909000 JavaThread "C2 CompilerThread0" daemon [_thread_blocked, id=5396, stack(0x000000000bf60000,0x000000000c060000)]
  0x000000000a907800 JavaThread "JDWP Command Reader" daemon [_thread_in_native, id=3696, stack(0x000000000c450000,0x000000000c550000)]
  0x000000000a8f8800 JavaThread "JDWP Event Helper Thread" daemon [_thread_blocked, id=2228, stack(0x000000000c220000,0x000000000c320000)]
  0x000000000a8e8000 JavaThread "JDWP Transport Listener: dt_socket" daemon [_thread_blocked, id=5552, stack(0x000000000bd20000,0x000000000be20000)]
  0x000000000a8e1000 JavaThread "Attach Listener" daemon [_thread_blocked, id=3220, stack(0x000000000b6c0000,0x000000000b7c0000)]
  0x000000000a8e0000 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=5924, stack(0x000000000ba60000,0x000000000bb60000)]
  0x000000000250f800 JavaThread "Finalizer" daemon [_thread_blocked, id=4924, stack(0x000000000b7f0000,0x000000000b8f0000)]
  0x000000000250b800 JavaThread "Reference Handler" daemon [_thread_blocked, id=1056, stack(0x000000000b590000,0x000000000b690000)]

Other Threads:
  0x0000000002508000 VMThread [stack: 0x000000000b3b0000,0x000000000b4b0000] [id=3668]
  0x000000000a923800 WatcherThread [stack: 0x000000000c980000,0x000000000ca80000] [id=7004]

VM state:not at safepoint (normal execution)

VM Mutex/Monitor currently owned by a thread: None

Heap
 PSYoungGen      total 38912K, used 6488K [0x00000007d5500000, 0x00000007d8000000, 0x0000000800000000)
  eden space 33792K, 19% used [0x00000007d5500000,0x00000007d5b56268,0x00000007d7600000)
  from space 5120K, 0% used [0x00000007d7b00000,0x00000007d7b00000,0x00000007d8000000)
  to   space 5120K, 0% used [0x00000007d7600000,0x00000007d7600000,0x00000007d7b00000)
 ParOldGen       total 87040K, used 0K [0x0000000780000000, 0x0000000785500000, 0x00000007d5500000)
  object space 87040K, 0% used [0x0000000780000000,0x0000000780000000,0x0000000785500000)
 PSPermGen       total 21504K, used 4235K [0x000000077ae00000, 0x000000077c300000, 0x0000000780000000)
  object space 21504K, 19% used [0x000000077ae00000,0x000000077b222f90,0x000000077c300000)

Card table byte_map: [0x0000000005730000,0x0000000005b60000] byte_map_base: 0x0000000001b59000

Polling page: 0x0000000000320000

Code Cache  [0x0000000002670000, 0x00000000028e0000, 0x0000000005670000)
 total_blobs=301 nmethods=14 adapters=249 free_code_cache=48694Kb largest_free_block=49850368

Compilation events (10 events):
Event: 0.671 Thread 0x000000000a90c800    9             java.lang.Object::<init> (1 bytes)
Event: 0.672 Thread 0x000000000a90c800 nmethod 9 0x00000000026e1e10 code [0x00000000026e1f40, 0x00000000026e1fd8]
Event: 0.673 Thread 0x000000000a90c800   10             java.nio.Buffer::hasRemaining (17 bytes)
Event: 0.674 Thread 0x000000000a90c800 nmethod 10 0x00000000026e2050 code [0x00000000026e2180, 0x00000000026e21f8]
Event: 0.674 Thread 0x000000000a90c800   11             java.nio.DirectByteBuffer::ix (10 bytes)
Event: 0.674 Thread 0x000000000a90c800 nmethod 11 0x00000000026e0110 code [0x00000000026e0240, 0x00000000026e0298]
Event: 0.685 Thread 0x000000000a90c800   13   !         sun.nio.cs.ISO_8859_1$Encoder::encodeBufferLoop (135 bytes)
Event: 0.696 Thread 0x000000000a90c800 nmethod 13 0x00000000026e2750 code [0x00000000026e2920, 0x00000000026e3080]
Event: 0.716 Thread 0x000000000a90c800   14             java.lang.String::equals (81 bytes)
Event: 0.719 Thread 0x000000000a90c800 nmethod 14 0x00000000026dfb10 code [0x00000000026dfc60, 0x00000000026dff58]

GC Heap History (0 events):
No events

Deoptimization events (0 events):
No events

Internal exceptions (10 events):
Event: 0.762 Thread 0x000000000cabe800 Threw 0x00000007d5aabf88 at C:\jdk7u2_64p\jdk7u40\hotspot\src\share\vm\prims\jvm.cpp:1244
Event: 0.792 Thread 0x000000000cabe800 Threw 0x00000007d5aaf6c8 at C:\jdk7u2_64p\jdk7u40\hotspot\src\share\vm\prims\jvm.cpp:1244
Event: 0.793 Thread 0x000000000cabe800 Threw 0x00000007d5ab4d70 at C:\jdk7u2_64p\jdk7u40\hotspot\src\share\vm\prims\jvm.cpp:1244
Event: 0.793 Thread 0x000000000cabe800 Threw 0x00000007d5ab6ab0 at C:\jdk7u2_64p\jdk7u40\hotspot\src\share\vm\prims\jvm.cpp:1244
Event: 0.794 Thread 0x000000000cabe800 Threw 0x00000007d5ab8af0 at C:\jdk7u2_64p\jdk7u40\hotspot\src\share\vm\prims\jvm.cpp:1244
Event: 0.795 Thread 0x000000000cabe800 Threw 0x00000007d5ac3d80 at C:\jdk7u2_64p\jdk7u40\hotspot\src\share\vm\prims\jvm.cpp:1244
Event: 0.797 Thread 0x000000000cabe800 Threw 0x00000007d5ad2330 at C:\jdk7u2_64p\jdk7u40\hotspot\src\share\vm\prims\jvm.cpp:1244
Event: 0.797 Thread 0x000000000cabe800 Threw 0x00000007d5ad4bb8 at C:\jdk7u2_64p\jdk7u40\hotspot\src\share\vm\prims\jvm.cpp:1244
Event: 0.798 Thread 0x000000000cabe800 Threw 0x00000007d5ada890 at C:\jdk7u2_64p\jdk7u40\hotspot\src\share\vm\prims\jvm.cpp:1244
Event: 0.799 Thread 0x000000000cabe800 Threw 0x00000007d5ade7b8 at C:\jdk7u2_64p\jdk7u40\hotspot\src\share\vm\prims\jvm.cpp:1244

Events (10 events):
Event: 0.795 loading class 0x000000000cd83390
Event: 0.795 loading class 0x000000000cd83390 done
Event: 0.797 loading class 0x000000000cd68840
Event: 0.797 loading class 0x000000000cd68840 done
Event: 0.797 loading class 0x000000000cd850a0
Event: 0.797 loading class 0x000000000cd850a0 done
Event: 0.798 loading class 0x000000000cd854c0
Event: 0.798 loading class 0x000000000cd854c0 done
Event: 0.799 loading class 0x000000000cc29b80
Event: 0.799 loading class 0x000000000cc29b80 done


Dynamic libraries:
0x000000013f5b0000 - 0x000000013f5e3000 	C:\Program Files\Java\jre7\bin\javaw.exe
0x00000000779a0000 - 0x0000000077b49000 	C:\Windows\SYSTEM32\ntdll.dll
0x0000000077880000 - 0x000000007799f000 	C:\Windows\system32\kernel32.dll
0x000007fefda40000 - 0x000007fefdaab000 	C:\Windows\system32\KERNELBASE.dll
0x000007fefe750000 - 0x000007fefe82b000 	C:\Windows\system32\ADVAPI32.dll
0x000007fefdbb0000 - 0x000007fefdc4f000 	C:\Windows\system32\msvcrt.dll
0x000007fefe6b0000 - 0x000007fefe6cf000 	C:\Windows\SYSTEM32\sechost.dll
0x000007fefde50000 - 0x000007fefdf7d000 	C:\Windows\system32\RPCRT4.dll
0x0000000077780000 - 0x000000007787a000 	C:\Windows\system32\USER32.dll
0x000007fefe830000 - 0x000007fefe897000 	C:\Windows\system32\GDI32.dll
0x000007fefe490000 - 0x000007fefe49e000 	C:\Windows\system32\LPK.dll
0x000007feff7b0000 - 0x000007feff879000 	C:\Windows\system32\USP10.dll
0x000007fefc0f0000 - 0x000007fefc2e4000 	C:\Windows\WinSxS\amd64_microsoft.windows.common-controls_6595b64144ccf1df_6.0.7601.17514_none_fa396087175ac9ac\COMCTL32.dll
0x000007fefddd0000 - 0x000007fefde41000 	C:\Windows\system32\SHLWAPI.dll
0x000007fefe8a0000 - 0x000007fefe8ce000 	C:\Windows\system32\IMM32.DLL
0x000007feff960000 - 0x000007feffa69000 	C:\Windows\system32\MSCTF.dll
0x0000000062c00000 - 0x0000000062cd1000 	C:\Program Files\Java\jre7\bin\msvcr100.dll
0x0000000061bc0000 - 0x0000000062389000 	C:\Program Files\Java\jre7\bin\server\jvm.dll
0x000007fef2530000 - 0x000007fef2539000 	C:\Windows\system32\WSOCK32.dll
0x000007fefe8d0000 - 0x000007fefe91d000 	C:\Windows\system32\WS2_32.dll
0x000007feffca0000 - 0x000007feffca8000 	C:\Windows\system32\NSI.dll
0x000007fef9e50000 - 0x000007fef9e8b000 	C:\Windows\system32\WINMM.dll
0x0000000077b60000 - 0x0000000077b67000 	C:\Windows\system32\PSAPI.DLL
0x0000000065d70000 - 0x0000000065d7f000 	C:\Program Files\Java\jre7\bin\verify.dll
0x0000000062ed0000 - 0x0000000062ef8000 	C:\Program Files\Java\jre7\bin\java.dll
0x0000000061320000 - 0x0000000061355000 	C:\Program Files\Java\jre7\bin\jdwp.dll
0x0000000061710000 - 0x0000000061718000 	C:\Program Files\Java\jre7\bin\npt.dll
0x0000000062eb0000 - 0x0000000062ec5000 	C:\Program Files\Java\jre7\bin\zip.dll
0x0000000062b80000 - 0x0000000062b89000 	C:\Program Files\Java\jre7\bin\dt_socket.dll
0x000007fefae70000 - 0x000007fefae85000 	C:\Windows\system32\NLAapi.dll
0x000007fef2490000 - 0x000007fef24a5000 	C:\Windows\system32\napinsp.dll
0x000007fef2470000 - 0x000007fef2489000 	C:\Windows\system32\pnrpnsp.dll
0x000007fefcfb0000 - 0x000007fefd005000 	C:\Windows\System32\mswsock.dll
0x000007fefce30000 - 0x000007fefce8b000 	C:\Windows\system32\DNSAPI.dll
0x000007fef2460000 - 0x000007fef246b000 	C:\Windows\System32\winrnr.dll
0x000007fef22f0000 - 0x000007fef231f000 	C:\Program Files\Common Files\Microsoft Shared\Windows Live\WLIDNSP.DLL
0x000007fef9860000 - 0x000007fef9887000 	C:\Windows\system32\IPHLPAPI.DLL
0x000007fef9850000 - 0x000007fef985b000 	C:\Windows\system32\WINNSI.DLL
0x000007fef9370000 - 0x000007fef93c3000 	C:\Windows\System32\fwpuclnt.dll
0x000007fef24b0000 - 0x000007fef24b8000 	C:\Windows\system32\rasadhlp.dll
0x000007fefc940000 - 0x000007fefc947000 	C:\Windows\System32\wshtcpip.dll
0x0000000180000000 - 0x0000000180051000 	C:\Users\Student\Documents\Workspace\LWJGL\lib\natives\lwjgl64.dll
0x000007fef07a0000 - 0x000007fef08bd000 	C:\Windows\system32\OPENGL32.dll
0x000007fef2dd0000 - 0x000007fef2dfd000 	C:\Windows\system32\GLU32.dll
0x000007fee7540000 - 0x000007fee7631000 	C:\Windows\system32\DDRAW.dll
0x000007fef7b30000 - 0x000007fef7b38000 	C:\Windows\system32\DCIMAN32.dll
0x000007fefdf80000 - 0x000007fefe157000 	C:\Windows\system32\SETUPAPI.dll
0x000007fefd9a0000 - 0x000007fefd9d6000 	C:\Windows\system32\CFGMGR32.dll
0x000007feff880000 - 0x000007feff957000 	C:\Windows\system32\OLEAUT32.dll
0x000007fefe4a0000 - 0x000007fefe6a3000 	C:\Windows\system32\ole32.dll
0x000007fefdb70000 - 0x000007fefdb8a000 	C:\Windows\system32\DEVOBJ.dll
0x000007fefbae0000 - 0x000007fefbaf8000 	C:\Windows\system32\dwmapi.dll
0x000007fefc870000 - 0x000007fefc87c000 	C:\Windows\system32\VERSION.dll
0x000007fefbf10000 - 0x000007fefbf66000 	C:\Windows\system32\uxtheme.dll
0x000000005f5f0000 - 0x0000000061317000 	C:\Windows\system32\nvoglv64.DLL
0x000007fefe980000 - 0x000007feff708000 	C:\Windows\system32\SHELL32.dll
0x000007fefd9e0000 - 0x000007fefda1a000 	C:\Windows\system32\WINTRUST.dll
0x000007fefd830000 - 0x000007fefd99c000 	C:\Windows\system32\CRYPT32.dll
0x000007fefd820000 - 0x000007fefd82f000 	C:\Windows\system32\MSASN1.dll
0x000007fefc6c0000 - 0x000007fefc6ed000 	C:\Windows\system32\ntmarta.dll
0x000007fefe920000 - 0x000007fefe972000 	C:\Windows\system32\WLDAP32.dll
0x000007fefd670000 - 0x000007fefd67f000 	C:\Windows\system32\CRYPTBASE.dll
0x000007fef9e90000 - 0x000007fef9f2c000 	C:\Windows\system32\mscms.dll
0x000007fefca80000 - 0x000007fefca9e000 	C:\Windows\system32\USERENV.dll
0x000007fefd780000 - 0x000007fefd78f000 	C:\Windows\system32\profapi.dll
0x000007fef2e20000 - 0x000007fef2e62000 	C:\Windows\system32\icm32.dll
0x000007fef7960000 - 0x000007fef7a85000 	C:\Windows\system32\dbghelp.dll

VM Arguments:
jvm_args: -agentlib:jdwp=transport=dt_socket,suspend=y,address=localhost:54176 -Djava.library.path=C:\Users\Student\Documents\Workspace\LWJGL\lib\natives;C:\Users\Student\Documents\Workspace\LWJGL\lib\natives -Dfile.encoding=UTF-8 
java_command: game.Game
Launcher Type: SUN_STANDARD

Environment Variables:
PATH=C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\TortoiseGit\bin;C:\Program Files\TortoiseSVN\bin;C:\Program Files\TortoiseHg\;C:\Program Files (x86)\Windows Live\Shared;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\
USERNAME=Student
OS=Windows_NT
PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 23 Stepping 10, GenuineIntel



---------------  S Y S T E M  ---------------

OS: Windows 7 , 64 bit Build 7601 Service Pack 1

CPU:total 2 (2 cores per cpu, 1 threads per core) family 6 model 23 stepping 10, cmov, cx8, fxsr, mmx, sse, sse2, sse3, ssse3, tsc

Memory: 4k page, physical 8387064k(4973272k free), swap 16772264k(12095700k free)

vm_info: Java HotSpot(TM) 64-Bit Server VM (24.0-b56) for windows-amd64 JRE (1.7.0_40-b43), built on Aug 26 2013 22:38:32 by "java_re" with unknown MS VC++:1600

time: Sat Feb 08 18:40:34 2014
elapsed time: 0 seconds



I’m going to continue to check for OpenGL errors.

Essentially that means that there are fewer than 24 vertices (a vertex as defined by your pointers) in the bound VBO. Check your pointer calls because that’s generally where the problems come up.

I checked high and low, but there’s no hint that the buffer size being incorrect is what causing the problem. The buffer size is exactly the same as what SHC’s tutorial taught: 24.

There are 24 vertices, and each of the vertex values, X, Y, and Z, are all GL_FLOATs. I used BufferUtils to create float buffers of vertex array length size, so I don’t think it’s that problem. The color float array is also of type floats, so the float buffer created via BufferUtils for that is the same.

The codes are the same as the ones posted in the first post. Nothing has changed so far.

Here, you are having an error on line 41 of the above posted code.


glBindBuffer(GL_ARRAY_BUFFER, cube.vboVertex);
glVertexPointer(3, GL_FLOAT, 0, 0L);
glBindBuffer(GL_ARRAY_BUFFER, cube.vboColor);
@@glVertexPointer(3, GL_FLOAT, 0, 0L);

Changing it to the following works.


glBindBuffer(GL_ARRAY_BUFFER, cube.vboVertex);
glVertexPointer(3, GL_FLOAT, 0, 0L);
glBindBuffer(GL_ARRAY_BUFFER, cube.vboColor);
@@glColorPointer(3, GL_FLOAT, 0, 0L);

Hope this helps.

AH! Code finally runs! ;D

Nevertheless, nothing is showing up. It’s like I’ve been cursed. :cranky:

:’( :emo:

Anyway, thanks for the help on finding the crash problem. This has been solved! Thank you guys!