public class RenderArea extends Inventor
RenderAreaListener
allows managing the renderArea events.ServiceSettings.INVENTOR_SERVICE
or ServiceSettings.INVENTOR_APPLICATION
service mode, this class provides access to the scene manager and the touch manager to modify the rendering.
Inventor.ConstructorCommand
VERBOSE_LEVEL, ZeroHandle
Modifier and Type | Method and Description |
---|---|
void |
addListener(RenderAreaListener listener)
Adds a
RenderAreaListener to manage the renderArea. |
void |
closeConnectionsAndDispose()
Closes all connections of the renderArea and disposes it.
|
Connection |
getConnection(int index)
Gets a
Connection to the renderArea. |
Connection |
getConnection(java.lang.String id)
Gets a
Connection to the renderArea. |
SoGLContext |
getGLContext()
Gets the OpenGL context of the renderArea.
|
java.lang.String |
getGpu()
Gets the Graphics Processing Unit (GPU) used to compute the render.
|
int |
getHeight()
Gets the renderArea height.
|
java.lang.String |
getId()
Gets the renderArea id.
|
int |
getNumConnections()
Gets the connections number of the renderArea.
|
int |
getNumListeners()
Gets the number of
RenderAreaListener . |
SoSceneManager |
getSceneManager()
Gets the Scene manager of the renderArea.
|
SoTouchManager |
getTouchManager()
Gets the Touch Manager of the renderArea.
|
int |
getWidth()
Gets the renderArea width.
|
void |
removeAllListeners()
Removes all RenderAreaListeners.
|
void |
removeListener(RenderAreaListener listener)
Removes a
RenderAreaListener . |
void |
resize(int width,
int height)
Resizes the renderArea at a specific size.
|
boolean |
sendMessage(java.lang.String message)
Calls sendMessage(message, (com.openinventor.remoteviz.rendering.Connection[])null).
|
boolean |
sendMessage(java.lang.String message,
Connection[] excludedConnections)
Sends a text message to the renderArea connections.
|
dispose, getAddress, getNativeResourceHandle, startInternalThreads, stopInternalThreads
public boolean sendMessage(java.lang.String message)
public SoSceneManager getSceneManager()
ServiceSettings.INDEPENDENT_SERVICE
mode, this method returns null.
public java.lang.String getGpu()
RenderAreaHardware.setGpu
public SoTouchManager getTouchManager()
ServiceSettings.INDEPENDENT_SERVICE
mode, this method returns null.
public int getNumConnections()
public Connection getConnection(java.lang.String id)
Connection
to the renderArea.
id
- : ID identifying the Connection
public java.lang.String getId()
public Connection getConnection(int index)
Connection
to the renderArea.
index
- : index identifying the Connection
public int getNumListeners()
RenderAreaListener
.
RenderAreaListener
.public int getHeight()
public void addListener(RenderAreaListener listener)
RenderAreaListener
to manage the renderArea.
listener
- : object that listens to the renderArea eventspublic void resize(int width, int height)
width
- : new width of the renderArea
height
- : new height of the renderAreapublic void closeConnectionsAndDispose()
ServiceListener.onDisposedRenderArea
will be triggered and a DISPOSED disconnect message will be sent to all clients of the renderArea. The callback RenderAreaListener.onClosedConnection
will not be triggered after closing connections.public int getWidth()
public void removeAllListeners()
public SoGLContext getGLContext()
ServiceSettings.INDEPENDENT_SERVICE
mode, this method returns null.
public void removeListener(RenderAreaListener listener)
RenderAreaListener
.
listener
- : object that listens to the renderArea eventspublic boolean sendMessage(java.lang.String message, Connection[] excludedConnections)
message
- : the message to be sent to all connections of the renderArea
excludedConnections
- : an excluded connections array
num
- : number of excluded connections
Generated on January 23, 2025, Copyright © Thermo Fisher Scientific. All rights reserved. http://www.openinventor.com