JOGL v2.6.0-rc-20250712
JOGL, High-Performance Graphics Binding for Java™ (public API).
com.jogamp.opengl.test.junit.jogl.acore.TestSingleGLInJSliderNewtAWT Class Reference

TestSingleGLInJSliderNewtAWT. More...

Inheritance diagram for com.jogamp.opengl.test.junit.jogl.acore.TestSingleGLInJSliderNewtAWT:
Collaboration diagram for com.jogamp.opengl.test.junit.jogl.acore.TestSingleGLInJSliderNewtAWT:

Classes

class  TwoTriangles
 

Public Member Functions

void test01UseAWTNotShared () throws InterruptedException, InvocationTargetException
 
void test10UseNEWTNotShared () throws InterruptedException, InvocationTargetException
 
void testCreateVisibleDestroy (final boolean useNewt) throws InterruptedException, InvocationTargetException
 Assemble the user interface and start the animator. More...
 
- Public Member Functions inherited from com.jogamp.opengl.test.junit.util.UITestCase
int getMaxTestNameLen ()
 
String getSnapshotFilename (final int sn, String postSNDetail, final GLCapabilitiesImmutable caps, final int width, final int height, final boolean sinkHasAlpha, String fileSuffix, final String destPath)
 
void snapshot (final int sn, final String postSNDetail, final GL gl, final GLReadBufferUtil readBufferUtil, final String fileSuffix, final String destPath)
 Takes a snapshot of the drawable's current front framebuffer. More...
 

Static Public Member Functions

static void initClass ()
 
static void logAnyErrorCodes (final Object obj, final GL gl, final String prefix)
 
static float setupViewFrustum (final GL2 gl2, final int width, final int height, final float boundsRadius, final float zoomFactor, final float viewFovDegrees)
 Sets the OpenGL projection matrix and front and back clipping planes for a viewport and returns the distance the camera should be placed from the center of the scene's bounding sphere such that the geometry is centered in the view frustum. More...
 
static void main (final String[] args) throws IOException
 
- Static Public Member Functions inherited from com.jogamp.opengl.test.junit.util.UITestCase
static void setResetXRandRIfX11AfterClass ()
 
static int resetXRandRIfX11 ()
 Iterates through all outputs and sets the preferred mode and normal rotation using RandR 1.3. More...
 
static int processCommand (final String[] cmdline, final OutputStream outstream, final StringBuilder outstring, final String outPrefix)
 
static final void oneTimeSetUpUITest ()
 
static final void oneTimeTearDownUITest ()
 

Detailed Description

TestSingleGLInJSliderNewtAWT.

Opens a single JFrame with one OpenGL widget and sliders to adjust the view orientation.

The OpenGL widget renders a red triangle and a blue triangle.

If static useNewt is true, then those OpenGL widgets are GLWindow objects in a NewtCanvasAWT. If static useNewt is false, then those OpenGL widgets are GLCanvas objects.

Definition at line 92 of file TestSingleGLInJSliderNewtAWT.java.

Member Function Documentation

◆ initClass()

static void com.jogamp.opengl.test.junit.jogl.acore.TestSingleGLInJSliderNewtAWT.initClass ( )
static

Definition at line 101 of file TestSingleGLInJSliderNewtAWT.java.

Here is the call graph for this function:

◆ logAnyErrorCodes()

static void com.jogamp.opengl.test.junit.jogl.acore.TestSingleGLInJSliderNewtAWT.logAnyErrorCodes ( final Object  obj,
final GL  gl,
final String  prefix 
)
static

Definition at line 386 of file TestSingleGLInJSliderNewtAWT.java.

Here is the call graph for this function:

◆ main()

static void com.jogamp.opengl.test.junit.jogl.acore.TestSingleGLInJSliderNewtAWT.main ( final String[]  args) throws IOException
static

Definition at line 671 of file TestSingleGLInJSliderNewtAWT.java.

◆ setupViewFrustum()

static float com.jogamp.opengl.test.junit.jogl.acore.TestSingleGLInJSliderNewtAWT.setupViewFrustum ( final GL2  gl2,
final int  width,
final int  height,
final float  boundsRadius,
final float  zoomFactor,
final float  viewFovDegrees 
)
static

Sets the OpenGL projection matrix and front and back clipping planes for a viewport and returns the distance the camera should be placed from the center of the scene's bounding sphere such that the geometry is centered in the view frustum.

Parameters
gl2current OpenGL context
widthwidth of GLDrawable
heightheight of GLDrawable
boundsRadiusradius of a minimal bounding sphere of objects to be rendered in the viewport
zoomFactoraffects how far away the camera is placed from the scene; changing the zoom from 1.0 to 0.5 would make the scene appear half the size
viewFovDegreesthe desired field of vision for the viewport, higher is more fish-eye
Returns
the distance the camera should be from the center of the scenes bounding sphere

Definition at line 423 of file TestSingleGLInJSliderNewtAWT.java.

Here is the call graph for this function:

◆ test01UseAWTNotShared()

void com.jogamp.opengl.test.junit.jogl.acore.TestSingleGLInJSliderNewtAWT.test01UseAWTNotShared ( ) throws InterruptedException, InvocationTargetException

Definition at line 443 of file TestSingleGLInJSliderNewtAWT.java.

◆ test10UseNEWTNotShared()

void com.jogamp.opengl.test.junit.jogl.acore.TestSingleGLInJSliderNewtAWT.test10UseNEWTNotShared ( ) throws InterruptedException, InvocationTargetException

Definition at line 448 of file TestSingleGLInJSliderNewtAWT.java.

◆ testCreateVisibleDestroy()

void com.jogamp.opengl.test.junit.jogl.acore.TestSingleGLInJSliderNewtAWT.testCreateVisibleDestroy ( final boolean  useNewt) throws InterruptedException, InvocationTargetException

Assemble the user interface and start the animator.

It waits until the window is closed an then attempts orderly shutdown and resource deallocation.

Definition at line 456 of file TestSingleGLInJSliderNewtAWT.java.

Here is the call graph for this function:

The documentation for this class was generated from the following file: