From 45188f32557fade1d4d289e84de54aeee9d1efa3 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Fri, 17 Dec 2010 00:16:13 +0100 Subject: SharedResourceRunner: Expose convenient 'getShared()' w/o creation --- src/jogl/classes/com/jogamp/opengl/impl/SharedResourceRunner.java | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/jogl') diff --git a/src/jogl/classes/com/jogamp/opengl/impl/SharedResourceRunner.java b/src/jogl/classes/com/jogamp/opengl/impl/SharedResourceRunner.java index 1ea83f84a..765c6620d 100644 --- a/src/jogl/classes/com/jogamp/opengl/impl/SharedResourceRunner.java +++ b/src/jogl/classes/com/jogamp/opengl/impl/SharedResourceRunner.java @@ -83,6 +83,11 @@ public class SharedResourceRunner implements Runnable { this.impl = impl; } + public SharedResourceRunner.Resource getShared(AbstractGraphicsDevice device) { + String connection = device.getConnection(); + return impl.mapGet(connection); + } + public SharedResourceRunner.Resource getOrCreateShared(AbstractGraphicsDevice device) { String connection = device.getConnection(); SharedResourceRunner.Resource sr = impl.mapGet(connection); -- cgit v1.2.3