Whats Better For Game Programming

Alright I’m wondering what is better for 3-D Game Programming.

C++ or Java, I heard java is more based for game
I heard C++ was amazing for games also.

A couple questions,

since I don’t know much on Java does it support OpenGL and DirectX,
I Did more information on C++ then java, so I was wondering if you guys could tell me more about java thanks.