当前位置: 首页>>代码示例>>Java>>正文


Java Animator.start方法代码示例

本文整理汇总了Java中com.jogamp.opengl.util.Animator.start方法的典型用法代码示例。如果您正苦于以下问题:Java Animator.start方法的具体用法?Java Animator.start怎么用?Java Animator.start使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.jogamp.opengl.util.Animator的用法示例。


在下文中一共展示了Animator.start方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: Picking

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
Picking()
{
  Frame frame = new Frame("Picking Example");
  GLCapabilities capabilities = new GLCapabilities(null);
  GLCanvas drawable = new GLCanvas(capabilities);
  final Renderer renderer = new Renderer();
  drawable.addGLEventListener(renderer);
  drawable.addMouseListener(renderer);
  drawable.addMouseMotionListener(renderer);
  frame.add(drawable);
  frame.setSize(400, 400);
  final Animator animator = new Animator(drawable);
  frame.addWindowListener(new WindowAdapter()
    {
      public void windowClosing(WindowEvent e) 
      {
        animator.stop();
        System.exit(0);
      }
    });
  frame.setVisible(true);
  animator.start();	
}
 
开发者ID:ec-europa,项目名称:sumo,代码行数:24,代码来源:Picking.java

示例2: setup

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
private void setup() {

        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);

        window = GLWindow.create(glCapabilities);

        window.setTitle("Hello Triangle (enhanced)");
        window.setSize(1024, 768);

        window.setVisible(true);

        window.addGLEventListener(this);
        window.addKeyListener(this);

        animator = new Animator(window);
        animator.start();

        window.addWindowListener(new WindowAdapter() {
            @Override
            public void windowDestroyed(WindowEvent e) {
                animator.stop();
                System.exit(1);
            }
        });
    }
 
开发者ID:java-opengl-labs,项目名称:hello-triangle,代码行数:27,代码来源:HelloTriangle.java

示例3: setup

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
private void setup() {

        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);

        window = GLWindow.create(glCapabilities);

        window.setTitle("Input into rendering");
        window.setSize(1024, 768);

        window.addGLEventListener(this);
        window.addKeyListener(this);

        window.setVisible(true);

        animator = new Animator(window);
        animator.start();

        window.addWindowListener(new WindowAdapter() {
            @Override
            public void windowDestroyed(WindowEvent e) {
                animator.stop();
                System.exit(1);
            }
        });
    }
 
开发者ID:java-opengl-labs,项目名称:hello-triangle,代码行数:27,代码来源:Input_into_rendering.java

示例4: OpenGLViewer

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
public OpenGLViewer (String title){
	super(title);
	panel = new GLJPanel();
	panel.addGLEventListener(this);
	panel.setPreferredSize(new Dimension(width, height));
	edu.stanford.rsl.conrad.cuda.MouseControl mouseControl = new edu.stanford.rsl.conrad.cuda.MouseControl(this);
	panel.addMouseMotionListener(mouseControl);
	panel.addMouseWheelListener(mouseControl);
	this.add(panel);
	pack();
	setVisible(true);
	boolean animate = true;
	if (animate) {
		animator = new Animator(panel);
		animator.setRunAsFastAsPossible(true);
		animator.start();
	}

	addWindowListener(new WindowAdapter()
	{
		public void windowClosing(WindowEvent e)
		{
			runExit();
		}
	});
}
 
开发者ID:akmaier,项目名称:CONRAD,代码行数:27,代码来源:OpenGLViewer.java

示例5: main

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
public static void main(String[] args) {

        Display display = NewtFactory.createDisplay(null);
        Screen screen = NewtFactory.createScreen(display, 0);
        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);
        glWindow = GLWindow.create(screen, glCapabilities);

        glWindow.setSize(1044, 768);
        glWindow.setPosition(100, 50);
        glWindow.setUndecorated(false);
        glWindow.setAlwaysOnTop(false);
        glWindow.setFullscreen(false);
        glWindow.setPointerVisible(true);
        glWindow.confinePointer(false);
        glWindow.setTitle("Tutorial 09 - Interpolation");
        glWindow.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG);
        glWindow.setVisible(true);

        Tutorial09 tutorial09 = new Tutorial09();
        glWindow.addGLEventListener(tutorial09);

        animator = new Animator(glWindow);
        animator.start();
    }
 
开发者ID:java-opengl-labs,项目名称:ogl-dev,代码行数:26,代码来源:Tutorial09.java

示例6: main

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
public static void main(String[] args) {

        Display display = NewtFactory.createDisplay(null);
        Screen screen = NewtFactory.createScreen(display, 0);
        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);
        glWindow = GLWindow.create(screen, glCapabilities);

        glWindow.setSize(1044, 768);
        glWindow.setPosition(100, 50);
        glWindow.setUndecorated(false);
        glWindow.setAlwaysOnTop(false);
        glWindow.setFullscreen(false);
        glWindow.setPointerVisible(true);
        glWindow.confinePointer(false);
        glWindow.setTitle("Tutorial 05 - Uniform Variables");
        glWindow.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG);
        glWindow.setVisible(true);

        Tutorial05 tutorial05 = new Tutorial05();
        glWindow.addGLEventListener(tutorial05);

        animator = new Animator(glWindow);
        animator.start();
    }
 
开发者ID:java-opengl-labs,项目名称:ogl-dev,代码行数:26,代码来源:Tutorial05.java

示例7: main

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
public static void main(String[] args) {

        Display display = NewtFactory.createDisplay(null);
        Screen screen = NewtFactory.createScreen(display, 0);
        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);
        glWindow = GLWindow.create(screen, glCapabilities);

        glWindow.setSize(1034, 768);
        glWindow.setPosition(100, 50);
        glWindow.setUndecorated(false);
        glWindow.setAlwaysOnTop(false);
        glWindow.setFullscreen(false);
        glWindow.setPointerVisible(true);
        glWindow.confinePointer(false);
        glWindow.setTitle("Tutorial 03 - First triangle");
        glWindow.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG);
        glWindow.setVisible(true);

        Tutorial03 tutorial03 = new Tutorial03();
        glWindow.addGLEventListener(tutorial03);

        animator = new Animator(glWindow);
        animator.start();
    }
 
开发者ID:java-opengl-labs,项目名称:ogl-dev,代码行数:26,代码来源:Tutorial03.java

示例8: main

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
public static void main(String[] args) {

        Display display = NewtFactory.createDisplay(null);
        Screen screen = NewtFactory.createScreen(display, 0);
        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);
        glWindow = GLWindow.create(screen, glCapabilities);

        glWindow.setSize(1044, 768);
        glWindow.setPosition(100, 50);
        glWindow.setUndecorated(false);
        glWindow.setAlwaysOnTop(false);
        glWindow.setFullscreen(false);
        glWindow.setPointerVisible(true);
        glWindow.confinePointer(false);
        glWindow.setTitle("Tutorial 04 - Shaders");
        glWindow.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG);
        glWindow.setVisible(true);

        Tutorial04 tutorial04 = new Tutorial04();
        glWindow.addGLEventListener(tutorial04);

        animator = new Animator(glWindow);
        animator.start();
    }
 
开发者ID:java-opengl-labs,项目名称:ogl-dev,代码行数:26,代码来源:Tutorial04.java

示例9: main

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
public static void main(String[] args) {

        Display display = NewtFactory.createDisplay(null);
        Screen screen = NewtFactory.createScreen(display, 0);
        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);
        glWindow = GLWindow.create(screen, glCapabilities);

        glWindow.setSize(1044, 768);
        glWindow.setPosition(100, 50);
        glWindow.setUndecorated(false);
        glWindow.setAlwaysOnTop(false);
        glWindow.setFullscreen(false);
        glWindow.setPointerVisible(true);
        glWindow.confinePointer(false);
        glWindow.setTitle("Tutorial 06 - Translation Transformation");
        glWindow.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG);
        glWindow.setVisible(true);

        Tutorial06 tutorial06 = new Tutorial06();
        glWindow.addGLEventListener(tutorial06);

        animator = new Animator(glWindow);
        animator.start();
    }
 
开发者ID:java-opengl-labs,项目名称:ogl-dev,代码行数:26,代码来源:Tutorial06.java

示例10: main

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
public static void main(String[] args) {

        Display display = NewtFactory.createDisplay(null);
        Screen screen = NewtFactory.createScreen(display, 0);
        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);
        glWindow = GLWindow.create(screen, glCapabilities);

        glWindow.setSize(1024, 768);
        glWindow.setPosition(100, 50);
        glWindow.setUndecorated(false);
        glWindow.setAlwaysOnTop(false);
        glWindow.setFullscreen(false);
        glWindow.setPointerVisible(true);
        glWindow.confinePointer(false);
        glWindow.setTitle("Tutorial 02 -  Hello Dot");
        glWindow.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG);
        glWindow.setVisible(true);

        Tutorial02 tutorial02 = new Tutorial02();
        glWindow.addGLEventListener(tutorial02);

        animator = new Animator(glWindow);
        animator.start();
    }
 
开发者ID:java-opengl-labs,项目名称:ogl-dev,代码行数:26,代码来源:Tutorial02.java

示例11: main

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
public static void main(String[] args) {

        Display display = NewtFactory.createDisplay(null);
        Screen screen = NewtFactory.createScreen(display, 0);
        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);
        glWindow = GLWindow.create(screen, glCapabilities);

        glWindow.setSize(1044, 768);
        glWindow.setPosition(100, 50);
        glWindow.setUndecorated(false);
        glWindow.setAlwaysOnTop(false);
        glWindow.setFullscreen(false);
        glWindow.setPointerVisible(true);
        glWindow.confinePointer(false);
        glWindow.setTitle("Tutorial 07 - Rotation Transformation");
        glWindow.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG);
        glWindow.setVisible(true);

        Tutorial07 tutorial07 = new Tutorial07();
        glWindow.addGLEventListener(tutorial07);

        animator = new Animator(glWindow);
        animator.start();
    }
 
开发者ID:java-opengl-labs,项目名称:ogl-dev,代码行数:26,代码来源:Tutorial07.java

示例12: main

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
public static void main(String[] args) {

        Display display = NewtFactory.createDisplay(null);
        Screen screen = NewtFactory.createScreen(display, 0);
        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);
        glWindow = GLWindow.create(screen, glCapabilities);

        glWindow.setSize(1044, 768);
        glWindow.setPosition(100, 50);
        glWindow.setUndecorated(false);
        glWindow.setAlwaysOnTop(false);
        glWindow.setFullscreen(false);
        glWindow.setPointerVisible(true);
        glWindow.confinePointer(false);
        glWindow.setTitle("Tutorial10 - Indexed Draws");
        glWindow.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG);
        glWindow.setVisible(true);

        Tutorial10 tutorial10 = new Tutorial10();
        glWindow.addGLEventListener(tutorial10);

        animator = new Animator(glWindow);
        animator.start();
    }
 
开发者ID:java-opengl-labs,项目名称:ogl-dev,代码行数:26,代码来源:Tutorial10.java

示例13: FeaturePointsCanvas

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
public FeaturePointsCanvas(ProjectTopComponent tc) {
    super(tc);

    GLCapabilities capabilities = new GLCapabilities(GLProfile.get(GLProfile.GL2));
    capabilities.setDoubleBuffered(true);
    //    capabilities.setAlphaBits(0);
    glJPanel = new GLJPanel(capabilities);
    glAnimatorControl = new Animator(glJPanel);
    glAnimatorControl.start();
    initComponents();

    jPanel2.add(glJPanel);
    this.validate();
}
 
开发者ID:Fidentis,项目名称:Analyst,代码行数:15,代码来源:FeaturePointsCanvas.java

示例14: setup

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
private void setup() {

        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);

        window = GLWindow.create(glCapabilities);

        window.setTitle("Hello Triangle (enhanced)");
        window.setSize(1024, 768);

        window.addGLEventListener(this);
        window.addKeyListener(this);

        window.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG);
        window.setVisible(true);

        animator = new Animator(window);
        animator.start();

        window.addWindowListener(new WindowAdapter() {
            @Override
            public void windowDestroyed(WindowEvent e) {
                animator.stop();
                System.exit(1);
            }
        });
    }
 
开发者ID:java-opengl-labs,项目名称:hello-triangle,代码行数:28,代码来源:HelloTriangle.java

示例15: setup

import com.jogamp.opengl.util.Animator; //导入方法依赖的package包/类
private void setup() {

        GLProfile glProfile = GLProfile.get(GLProfile.GL3);
        GLCapabilities glCapabilities = new GLCapabilities(glProfile);

        window = GLWindow.create(glCapabilities);

        window.setTitle("Hello Globe");
        window.setSize(1024, 768);

        window.setContextCreationFlags(GLContext.CTX_OPTION_DEBUG);
        window.setVisible(true);

        window.addGLEventListener(this);
        window.addKeyListener(this);

        animator = new Animator(window);
        animator.start();

        window.addWindowListener(new WindowAdapter() {
            @Override
            public void windowDestroyed(WindowEvent e) {
                animator.stop();
                System.exit(1);
            }
        });
    }
 
开发者ID:java-opengl-labs,项目名称:hello-triangle,代码行数:28,代码来源:HelloGlobe.java


注:本文中的com.jogamp.opengl.util.Animator.start方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。