GithubHelp home page GithubHelp logo

jmiskovic / lovr-phyedit Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 0.0 561 KB

VR graphical editor for LÖVR physics simulation

License: MIT License

Lua 99.65% GLSL 0.35%
editor gui physics-simulation sandbox-playground vr

lovr-phyedit's Introduction

lovr-phyedit

VR editor for creating and testing the virtual physics simulations. It exposes most of the LÖVR's features for physics world, colliders, shapes and joints, with notable exceptions of tags, mesh shape and terrain shape.

screenshot

Beware, this is a pre-alpha quality release - it is not well tested and can be prone to crashes. I would welcome any issue reports, feature requests, pull requests or any other feedback.

Controls

Either hand can operate all the listed commands.

  • Use Trigger to interact with UI Windows
  • Point at the collider and use A or X button to select it
  • Hold the GRIP button and move the hand to push the selected collider around
  • Use thumbstick while holding the GRIP to rotate the selected collider

Scenes window

Saving and loading of saved scenes. The files themselves can be found in the save directory:

  • Linux: /home/<user>/.local/share/LOVR/phyedit/
  • Windows: C:\Users\<user>\AppData\Roaming\LOVR\phyedit\
  • macOS: /Users/<user>/Library/Application Support/LOVR/phyedit/

scenes_screen

Scene is saved as plain-text serialized Lua, it can be loaded into other projects by using phywire library using the "snapshot" feature.

World settings window

Allows changing the global physics world settings.

Note that damping settings and sleeping-allowed setting only affects newly created colliders and won't have effect on already existing ones (they can still be modified individually).

world_screen

At the bottom of the window are four buttons for creating new colliders with various initial shapes. They will be placed in front of the camera and will have an initial size which can later be changed in collider window.

Visualization settings window

The window allows enabling and disabling various physics visualizations, and controlling the simulation speed. For more information about each setting check the phywire library.

visualization_screen

The pause button stops the simulation, while the framerate controls the physics update delta time.

Collider window

The most complex window is the collider window which operates on the currently selected collider.

First group of settings affects the whole collider. After that is the dynamically expanding list of each shape belonging to the collider, together with its settings. Note that when changing shape position the collider will behave unrealistically if its shapes are not balanced so that the center of mass falls in the collider origin. Achieving this with manual tweaking is not really practical, needs improvement.

It is also possible to delete individual shapes. If the last shape is deleted the collider will remain empty (this is not really an issue for the simulation except it won't be possible to re-select such collider). Shapes can be freely added into the same collider until the window becomes too large and unwieldy (needs improvement).

collider_screen

At the bottom of the window are physical joint features. To create a collider, click on the button and select the other collider (A or X button). Make sure that "joints" option is selected in the visualization window to be able to see the joints.

Because the joint is a connection between two colliders, the exact same joint will be shown when any of the two colliders is selected. After joint is selected, it can be removed, or its parameters can be modified. Currently it is not possible to modify the anchor points or axes for joints, needs improvement.

Dependencies

The phyedit leverages these libraries (included in the project).

lovr-phyedit's People

Contributors

jmiskovic avatar

Stargazers

 avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.