org.jbox2d.profile
Class PistonBenchmark

java.lang.Object
  extended by org.jbox2d.profile.BasicPerformanceTest
      extended by org.jbox2d.profile.SettingsPerformanceTest
          extended by org.jbox2d.profile.PistonBenchmark

public class PistonBenchmark
extends SettingsPerformanceTest

Benchmark - piston example (constantly bumping a bunch of circles and boxes). Should be a decent mix of circle and polygon collisions/contacts, though very little joint work. NOTE: some iterations cause objects to fall through the piston


Field Summary
static int frames
           
static int iters
           
 RevoluteJoint m_joint1
           
 PrismaticJoint m_joint2
           
static int posIters
           
static float timeStep
           
static int velIters
           
 World world
           
 
Fields inherited from class org.jbox2d.profile.BasicPerformanceTest
times
 
Constructor Summary
PistonBenchmark()
           
 
Method Summary
 int getFrames(int testNum)
           
static void main(String[] args)
           
 void runBenchmarkWorld()
           
 
Methods inherited from class org.jbox2d.profile.SettingsPerformanceTest
getTestName, runTest
 
Methods inherited from class org.jbox2d.profile.BasicPerformanceTest
getTestTime, go, printf, println, printResults
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

iters

public static int iters

frames

public static int frames

timeStep

public static float timeStep

velIters

public static int velIters

posIters

public static int posIters

m_joint1

public RevoluteJoint m_joint1

m_joint2

public PrismaticJoint m_joint2

world

public World world
Constructor Detail

PistonBenchmark

public PistonBenchmark()
Method Detail

main

public static void main(String[] args)

runBenchmarkWorld

public void runBenchmarkWorld()
Specified by:
runBenchmarkWorld in class SettingsPerformanceTest

getFrames

public int getFrames(int testNum)
Overrides:
getFrames in class BasicPerformanceTest


Copyright © 2013. All Rights Reserved.