{"id":17250073,"url":"https://github.com/stephengold/sport","last_synced_at":"2025-07-09T21:35:15.406Z","repository":{"id":226708461,"uuid":"769421404","full_name":"stephengold/sport","owner":"stephengold","description":"A simple 3-D graphics engine for Libbulletjme, based on OpenGL","archived":false,"fork":false,"pushed_at":"2025-07-05T20:58:49.000Z","size":1643,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-05T21:37:10.526Z","etag":null,"topics":["3d-graphics","assimp","engine","glfw","graphics","graphics-engine","java","joml","jvm-library","library","lwjgl3","open-source","opengl","opengl-engine","phong","shaders"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/stephengold.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-03-09T03:09:54.000Z","updated_at":"2025-07-05T20:58:53.000Z","dependencies_parsed_at":"2024-03-09T06:30:50.278Z","dependency_job_id":"ed0a0004-fd2f-4ec3-9f75-381a49a84bab","html_url":"https://github.com/stephengold/sport","commit_stats":null,"previous_names":["stephengold/sport"],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/stephengold/sport","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stephengold%2Fsport","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stephengold%2Fsport/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stephengold%2Fsport/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stephengold%2Fsport/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/stephengold","download_url":"https://codeload.github.com/stephengold/sport/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/stephengold%2Fsport/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264503949,"owners_count":23618763,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["3d-graphics","assimp","engine","glfw","graphics","graphics-engine","java","joml","jvm-library","library","lwjgl3","open-source","opengl","opengl-engine","phong","shaders"],"created_at":"2024-10-15T06:46:06.942Z","updated_at":"2025-07-09T21:35:15.384Z","avatar_url":"https://github.com/stephengold.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cimg height=\"150\" src=\"https://i.imgur.com/YEPFEcx.png\" alt=\"Libbulletjme Project logo\"\u003e\n\n[The SPORT Project][project] implements\nan [OpenGL]-based graphics engine\nfor [the Libbulletjme 3-D physics library][libbulletjme].\n\nIt contains 2 subprojects:\n\n1. lib: the SPORT graphics engine (a single JVM runtime library)\n2. apps: demos and non-automated test software\n\nComplete source code (in [Java]) is provided under\n[a 3-clause BSD license][license].\n\n\n\u003ca name=\"toc\"\u003e\u003c/a\u003e\n\n## Contents of this document\n\n+ [About SPORT](#about)\n+ [How to add SPORT to an existing project](#add)\n+ [How to build and run SPORT from source](#build)\n+ [Conventions](#conventions)\n+ [What's missing](#todo)\n+ [History](#history)\n+ [Acknowledgments](#acks)\n\n\n\u003ca name=\"about\"\u003e\u003c/a\u003e\n\n## About SPORT\n\nSPORT is a Simple Physics-ORienTed graphics engine written in Java 1.8.\nIn addition to [Libbulletjme],\nit uses [LWJGL], [Assimp], [GLFW], [JOML], [jSnapLoader], and [OpenGL].\nIt has been tested on Windows, Linux, and macOS.\n\n[Jump to the table of contents](#toc)\n\n\n\u003ca name=\"add\"\u003e\u003c/a\u003e\n\n## How to add SPORT to an existing project\n\nSPORT comes pre-built as a single library\nthat can be downloaded from Maven Central or GitHub.\nHowever, the native-library dependencies are intentionally omitted from SPORT's POM\nso developers can specify *which* Libbulletjme and LWJGL natives should be used.\n\nFor projects built using [Maven] or [Gradle], it is\n*not* sufficient to specify the\ndependency on the SPORT Library.\nYou must also explicitly specify the native-library dependencies.\n\n### Gradle-built projects\n\nAdd to the project’s \"build.gradle\" or \"build.gradle.kts\" file:\n\n    repositories {\n        mavenCentral()\n    }\n    dependencies {\n        // JVM library:\n        implementation(\"com.github.stephengold:sport:0.9.6\")\n\n        // Libbulletjme native libraries:\n        runtimeOnly(\"com.github.stephengold:Libbulletjme-Linux64:22.0.1:SpDebug\")\n          // Libbulletjme native libraries for other platforms could be added.\n\n        // LWJGL native libraries:\n        runtimeOnly(\"org.lwjgl:lwjgl:3.3.6:natives-linux\")\n        runtimeOnly(\"org.lwjgl:lwjgl-assimp:3.3.6:natives-linux\")\n        runtimeOnly(\"org.lwjgl:lwjgl-glfw:3.3.6:natives-linux\")\n        runtimeOnly(\"org.lwjgl:lwjgl-opengl:3.3.6:natives-linux\")\n          // LWJGL native libraries for other platforms could be added.\n    }\n\nFor some older versions of Gradle,\nit's necessary to replace `implementation` with `compile`.\n\n### Coding a SPORT application\n\nEvery SPORT application should extend the `BasePhysicsApp` class,\nwhich provides hooks for:\n\n+ initializing the application,\n+ creating and configuring the application's physics space,\n+ populating the space with physics objects, and\n+ updating the space before each frame is rendered.\n\nThe graphics engine doesn't have a scene graph.\nInstead, it maintains an internal list of renderable objects,\ncalled *geometries*.\nInstantiating a geometry automatically adds it to the list\nand causes it to be visualized.\n\n+ To visualize the world (physics-space) coordinate axes,\n  instantiate one or more `LocalAxisGeometry` objects.\n\nBy default, physics objects are not visualized.\n\n+ To visualize the shape\n  of a `PhysicsCollisionObject` other than a `PhysicsSoftBody`,\n  invoke the `visualizeShape()` method on it.\n+ To visualize the local coordinate axes of a `PhysicsCollisionObject`,\n  invoke the `visualizeAxes()` method on it.\n+ To visualize the wheels of a `PhysicsVehicle`,\n  invoke the `visualizeWheels()` method on the vehicle.\n+ To visualize the bounding box of a `PhysicsCollisionObject`,\n  instantiate an `AabbGeometry` for the object.\n+ To visualize a `Constraint`,\n  instantiate a `ConstraintGeometry` for each end.\n+ To visualize the faces of a `PhysicsSoftBody`,\n  instantiate a `FacesGeometry` for it.\n+ To visualize the links of a `PhysicsSoftBody`,\n  instantiate a `LinksGeometry` for it.\n+ To visualize the pins of a `PhysicsSoftBody`,\n  instantiate a `PinsGeometry` for it.\n+ To visualize the wind acting on a `PhysicsSoftBody`,\n  instantiate a `WindVelocityGeometry` for the body.\n\n[Jump to the table of contents](#toc)\n\n\n\u003ca name=\"build\"\u003e\u003c/a\u003e\n\n## How to build and run SPORT from source\n\n### Initial build\n\n1. Install a [Java Development Kit (JDK)][adoptium],\n   if you don't already have one.\n2. Point the `JAVA_HOME` environment variable to your JDK installation:\n   (In other words, set it to the path of a directory/folder\n   containing a \"bin\" that contains a Java executable.\n   That path might look something like\n   \"C:\\Program Files\\Eclipse Adoptium\\jdk-17.0.3.7-hotspot\"\n   or \"/usr/lib/jvm/java-17-openjdk-amd64/\" or\n   \"/Library/Java/JavaVirtualMachines/zulu-17.jdk/Contents/Home\" .)\n  + using Bash or Zsh: `export JAVA_HOME=\"` *path to installation* `\"`\n  + using [Fish]: `set -g JAVA_HOME \"` *path to installation* `\"`\n  + using Windows Command Prompt: `set JAVA_HOME=\"` *path to installation* `\"`\n  + using PowerShell: `$env:JAVA_HOME = '` *path to installation* `'`\n3. Download and extract the SPORT source code from GitHub:\n  + using [Git]:\n    + `git clone https://github.com/stephengold/sport.git`\n    + `cd sport`\n4. Run the [Gradle] wrapper:\n  + using Bash or Fish or PowerShell or Zsh: `./gradlew build`\n  + using Windows Command Prompt: `.\\gradlew build`\n\nAfter a successful build,\nMaven artifacts will be found in \"lib/build/libs\".\n\nYou can install the artifacts to your local Maven repository:\n+ using Bash or Fish or PowerShell or Zsh: `./gradlew install`\n+ using Windows Command Prompt: `.\\gradlew install`\n\n### Demos\n\nSeven demo applications are included:\n+ ConveyorDemo\n+ NewtonsCradle\n+ Pachinko\n+ SplitDemo\n+ TestGearJoint\n+ ThousandCubes\n+ Windlass\n\nDocumentation for the demo apps is at\nhttps://stephengold.github.io/Libbulletjme/lbj-en/English/demos.html\n\n### Chooser\n\nA Swing-based chooser application is included.\nHowever, it doesn't work on macOS yet.\n\nTo run the chooser:\n+ using Bash or Fish or PowerShell or Zsh: `./gradlew AppChooser`\n+ using Windows Command Prompt: `.\\gradlew AppChooser`\n\n### Cleanup\n\nYou can restore the project to a pristine state:\n+ using Bash or Fish or PowerShell or Zsh: `./gradlew clean`\n+ using Windows Command Prompt: `.\\gradlew clean`\n\nNote:  these commands will delete any downloaded native libraries.\n\n[Jump to the table of contents](#toc)\n\n\n\u003ca name=\"conventions\"\u003e\u003c/a\u003e\n\n## Conventions\n\nPackage names begin with `com.github.stephengold` or `jme3utilities.minie`.\n\nThe source code and pre-built libraries are compatible with JDK 8.\n\nRotation signs, polygon windings, and 3-D coordinate axes\nare right-handed/counter-clockwise unless otherwise noted.\n\nAngles are quantified in *radians* unless otherwise noted.\n\nThe world coordinate system is assumed to be Z-forward, Y-up.\n\n[Jump to the table of contents](#toc)\n\n\n\u003ca name=\"todo\"\u003e\u003c/a\u003e\n\n## What's missing\n\nThis project is incomplete.\nFuture enhancements might include:\n\n+ graphics and physics on separate threads\n+ graphical user interface\n+ automated tests\n+ shadow rendering\n+ physically-based rendering\n+ more performance statistics\n+ sound effects\n+ skeletal animation\n+ run on mobile platforms (Android and/or iOS)\n\n[Jump to the table of contents](#toc)\n\n\n\u003ca name=\"history\"\u003e\u003c/a\u003e\n\n## History\n\nFrom March 2022 to March 2024, SPORT was a subproject of\n[the LbjExamples Project][lbjexamples].\n\nSince March 2024, SPORT has been a separate project, hosted at\n[GitHub][project].\n\n[Jump to the table of contents](#toc)\n\n\n\u003ca name=\"acks\"\u003e\u003c/a\u003e\n\n## Acknowledgments\n\nThe ThousandCubes demo app and most of the original graphics code\nwere authored by Yanis Boudiaf.\n\nThe IcosphereMesh class derives from source code\npublished by James Khan in May 2017.\n\nThe ConveyorDemo app derives from source code\ncontributed by \"qwq\" in March 2022.\n\nThis project has made use of the following libraries and software tools:\n\n  + the [Checkstyle] tool\n  + the [Firefox] web browser\n  + the [Git] revision-control system and GitK commit viewer\n  + the [GitKraken] client\n  + the [GLFW] library\n  + the [Gradle] build tool\n  + the [Java] compiler, standard doclet, and runtime environment\n  + [the Java OpenGL Math Library][joml]\n  + the [jSnapLoader] dynamic-library loader\n  + [the Lightweight Java Gaming Library][lwjgl]\n  + the [Linux Mint][mint] operating system\n  + the [Markdown] document-conversion tool\n  + the [Meld] visual merge tool\n  + the [NetBeans] integrated development environment\n  + [the Open Asset Import (Assimp) Library][assimp]\n  + the [OpenGL] API\n  + Microsoft Windows\n  + the [RenderDoc] graphics debugger\n\nI am grateful to [GitHub] and [Imgur]\nfor providing free hosting for this project\nand many other open-source projects.\n\nI'm also grateful to my dear Holly, for keeping me sane.\n\nIf I've misattributed anything or left anyone out, please let me know, so I can\ncorrect the situation: sgold@sonic.net\n\n[Jump to the table of contents](#toc)\n\n\n[adoptium]: https://adoptium.net/releases.html \"Adoptium Project\"\n[assimp]: https://www.assimp.org/ \"The Open Asset Importer Library\"\n[checkstyle]: https://checkstyle.org \"Checkstyle\"\n[firefox]: https://www.mozilla.org/en-US/firefox \"Firefox\"\n[fish]: https://fishshell.com/ \"Fish command-line shell\"\n[git]: https://git-scm.com \"Git\"\n[github]: https://github.com \"GitHub\"\n[gitkraken]: https://www.gitkraken.com \"GitKraken client\"\n[glfw]: https://www.glfw.org \"GLFW Library\"\n[gradle]: https://gradle.org \"Gradle Project\"\n[imgur]: https://imgur.com/ \"Imgur\"\n[java]: https://en.wikipedia.org/wiki/Java_(programming_language) \"Java programming language\"\n[joml]: https://joml-ci.github.io/JOML \"Java OpenGL Math Library\"\n[jsnaploader]: https://github.com/Electrostat-Lab/jSnapLoader \"the jSnapLoader Project\"\n[lbjexamples]: https://github.com/stephengold/LbjExamples \"LbjExamples Project\"\n[libbulletjme]: https://stephengold.github.io/Libbulletjme/lbj-en/English/overview.html \"Libbulletjme Project\"\n[license]: https://github.com/stephengold/sport/blob/master/LICENSE \"SPORT license\"\n[lwjgl]: https://www.lwjgl.org \"Lightweight Java Game Library\"\n[markdown]: https://daringfireball.net/projects/markdown \"Markdown Project\"\n[maven]: https://maven.apache.org \"Maven Project\"\n[meld]: https://meldmerge.org \"Meld merge tool\"\n[mint]: https://linuxmint.com \"Linux Mint Project\"\n[netbeans]: https://netbeans.org \"NetBeans Project\"\n[opengl]: https://www.khronos.org/opengl \"OpenGL API\"\n[project]: https://github.com/stephengold/sport \"SPORT Project\"\n[renderdoc]: https://renderdoc.org \"RenderDoc Project\"\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstephengold%2Fsport","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fstephengold%2Fsport","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fstephengold%2Fsport/lists"}