GithubHelp home page GithubHelp logo

frostkiwi / mirrorball Goto Github PK

View Code? Open in Web Editor NEW
49.0 3.0 4.0 216.36 MB

Multi-Media Adventure of WebApp + Video ( https://youtu.be/rJPKTCdk-WI ) and Summer of Maths Exposition 2023 submission

Home Page: https://mirrorball.frost.kiwi/

License: MIT License

HTML 7.21% GLSL 6.63% CSS 5.04% JavaScript 80.23% Shell 0.39% PowerShell 0.50%
graphics mirror panorama webgl some3

mirrorball's Introduction

🔮 Mathematical Magic Mirrorball 🪄

🇬🇧 English 🇯🇵 日本語
Watch the video 日本語版

A combination of Video and WebApp ( https://mirrorball.frost.kiwi ). While watching, viewers can directly interact with examples and visualizations, on a second device or a separate browser tab. The audience will be taken on a journey through the history and maths on the topic of the "Mirrorball projection".

Deceptively simple, it is an incredible intersection of Computer Science and Mathematics. This project has been made in conjuction with a paper in pre-print, which you can read on arXiv: https://arxiv.org/abs/2308.10991 . The paper was submitted to IJAT.

Features:

Discover the Mirror Ball Projection with colorful visualizations Export to Equirectangular / Lat-Long and play around with rotations
basic-demo.mp4
equirectangular.mp4

View the projection of a Mirrorball with different colorful visualizations to understand how the math works. You can project a:

  • photo
  • video
  • live webcam stream
  • capture card feed

Any format, which your web browser can decode is supported. That should cover all important file types. You can also export as a Equirectangular projection for use in other panorama software.

Photo contribution guide, as per announcement

As shown in the sample Pull Request #13, just commit the photo into any spot and mention how you want to be credited. To do so, you will need to fork this repo in the top right corner first. Then you can drag&drop the photo into the code. This will make GitHub officially credit you as contributor. I will move it to the correct folder (Example commit), crop, rotate the image and credit the author (Example Commit) and generate the thumbnail (Example commit).

If that's too troublesome: Just message me on any Social media or E-Mail me at [email protected].

Submission:

The photos in the "User submissions" tab were provided by:

Build instructions

If you want to run the code locally:

  • Clone the repo
  • Install Node.js
  • Run npm install in the repo's root directory to install the dependencies as defined by the package.json file
  • Run npx vite, so Vite will start a local server to test the code on

Credits:

  • The side controlbar is realized via the package lil-gui, package author: @georgealways
  • The debug statistics toggled in the settings tab is the evergreen stats.js, package author: @mrdoob
  • Debug interface in the settings tab for tracking down bugs especially on iOS is provided by the awesome eruda, package author: @liriliri
  • One key insight on state management to get redraws only when the user is actually touching the interface and be a static page otherwise was provided by @Pomax in this StackOverflow answer
  • Vector math performed via the package gl-matrix, package author: @toji

mirrorball's People

Contributors

frostkiwi avatar mothdotmonster avatar cigam-hfden avatar

Stargazers

Diego Carrasco Vásquez avatar Martynas Mickevičius avatar Colin B. avatar Zhao JIe avatar Caleb avatar Joseph Catrambone avatar JP avatar Robin Landström avatar Sarah Laplace avatar Alexis Quintero avatar  avatar Alan Acuña avatar  avatar Dongyu Yan avatar LuoJinhao avatar Rodbotic avatar Luka Micheletti avatar  avatar  avatar Yiwei Mao avatar Paulo Henrique Silva avatar Kyle Zheng avatar Rasmus Sehlin avatar Trafficone avatar Jason Schlesinger avatar Ozgur Gulsuna avatar  avatar  avatar  avatar  avatar Dante Broggi avatar Chuenhei Tai avatar Brian Wo avatar Nicola Sansoni avatar Amit Yadav avatar Serhii A. Hrytsenko avatar  avatar  avatar rusty_tendrils avatar Noah Sandman avatar Tuan Kuranes avatar sunguangdong avatar Samyak Wanjarwadkar avatar Raman Fedaseyeu avatar Aashirbad Bhandari avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

mirrorball's Issues

Gamepad code breaks webpage

If the user has a gamepad plugged in that does not have a button index 14, the web page crashes when trying to load media.

Uncaught TypeError: Cannot read properties of undefined (reading 'pressed')
at Ct (index-8efaa98d.js:612:13377)
at i (index-8efaa98d.js:612:17012)

Video does not play through to the end under certain conditions

This one I'm confused with.
There is no issue if the video file comes from the user's device, but from the server, only the first couple of seconds are played.
There is probably a conflict with buffering, pausing and the app resuming, that I never saw until now, since I always used the 4k² uncompressed files from local storage.

Not sure if I'll make it in time for the SoME3 deadline with this issue.

Lock controls during image loading

Whilst the spinner is active, the controls panel should be locked to prevent some edge cases of changing values, that are not well defined yet or will flip once media loading is complete.

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.