bpm2fps


Namebpm2fps JSON
Version 1.0.2 PyPI version JSON
download
home_pagehttps://github.com/BreadMakesYouFull/bpm2fps.git
SummaryConvert beats per minute to animation frames.
upload_time2024-08-29 02:20:17
maintainerNone
docs_urlNone
authorBreadMakesYouFull
requires_pythonNone
licenseMIT
keywords fps bpm calculate calculator usd animation anim reference
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # bpm2fps

Match song beats to their closest frame for animation.

* Utility to convert beats per minute to animation frames.
* Data export to CSV or JSON.
* USD export for bouncing ball reference.
* Also available as cli / python utility

[https://github.com/BreadMakesYouFull/bpm2fps](https://github.com/BreadMakesYouFull/bpm2fps)

## Preview

![GUI](https://raw.githubusercontent.com/BreadMakesYouFull/bpm2fps/main/preview_gui.gif)

![Exported USD reference](https://raw.githubusercontent.com/BreadMakesYouFull/bpm2fps/main/preview_usd.gif)

## Install

<a href='https://flathub.org/apps/io.github.breadmakesyoufull.bpm2fps'>
  <img width='128' alt='Get it on Flathub' src='https://flathub.org/api/badge?locale=en'/>
  Linux install via flatpak
</a>

[![PyPI version](https://badge.fury.io/py/bpm2fps.svg)](https://badge.fury.io/py/bpm2fps) [Python install](https://pypi.org/project/bpm2fps/)

[![](https://github.com/breadmakesyoufull/bpm2fps/actions/workflows/lint-then-test.yml/badge.svg)](https://github.com/BreadMakesYouFull/bpm2fps/actions/workflows/lint-then-test.yml)


Requires:

* python 3
* pyside6 (gui)

```
# Install
pip install bpm2fps[gui]

# ... or install without GUI
pip install bpm2fps
```

## GUI

```
# Launch GUI
bpm2fps
```

## Command line


### Usage

```
./bpm2fps.sh --help
usage: cli.py [-h] [-s START] [-e END] [-b BPM] [-f FPS]

bpm2fps - Match song beats to their closest frame.

options:
  -h, --help            show this help message and exit
  -s START, --start START
                        Start time (seconds).
  -e END, --end END     End time (seconds)
  -b BPM, --bpm BPM     Beats per minute
  -f FPS, --fps FPS     Frames per second
```

### Example
```
./bpm2fps.sh --bpm 120
# Result:
[
  {
    "beat": 0,
    "frame": 0.0,
    "second": 0.0
  },
  {
    "beat": 1,
    "frame": 12.0,
    "second": 0.5
  },
  {
    "beat": 2,
    "frame": 24.0,
    "second": 1.0
  },
  # ... and so on
]
```

Example chained with ``jq`` to get only beat frames:
```
./bpm2fps.sh --bpm 120 | jq '.[]["frame"]'
# Result:
0
12
24
36
48
60
72
84
96
108
```

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/BreadMakesYouFull/bpm2fps.git",
    "name": "bpm2fps",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": "fps bpm calculate calculator usd animation anim reference",
    "author": "BreadMakesYouFull",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/3f/41/913482070271b0f3630682702dcb583658560220b0e9f92fb9275c8a4381/bpm2fps-1.0.2.tar.gz",
    "platform": null,
    "description": "# bpm2fps\n\nMatch song beats to their closest frame for animation.\n\n* Utility to convert beats per minute to animation frames.\n* Data export to CSV or JSON.\n* USD export for bouncing ball reference.\n* Also available as cli / python utility\n\n[https://github.com/BreadMakesYouFull/bpm2fps](https://github.com/BreadMakesYouFull/bpm2fps)\n\n## Preview\n\n![GUI](https://raw.githubusercontent.com/BreadMakesYouFull/bpm2fps/main/preview_gui.gif)\n\n![Exported USD reference](https://raw.githubusercontent.com/BreadMakesYouFull/bpm2fps/main/preview_usd.gif)\n\n## Install\n\n<a href='https://flathub.org/apps/io.github.breadmakesyoufull.bpm2fps'>\n  <img width='128' alt='Get it on Flathub' src='https://flathub.org/api/badge?locale=en'/>\n  Linux install via flatpak\n</a>\n\n[![PyPI version](https://badge.fury.io/py/bpm2fps.svg)](https://badge.fury.io/py/bpm2fps) [Python install](https://pypi.org/project/bpm2fps/)\n\n[![](https://github.com/breadmakesyoufull/bpm2fps/actions/workflows/lint-then-test.yml/badge.svg)](https://github.com/BreadMakesYouFull/bpm2fps/actions/workflows/lint-then-test.yml)\n\n\nRequires:\n\n* python 3\n* pyside6 (gui)\n\n```\n# Install\npip install bpm2fps[gui]\n\n# ... or install without GUI\npip install bpm2fps\n```\n\n## GUI\n\n```\n# Launch GUI\nbpm2fps\n```\n\n## Command line\n\n\n### Usage\n\n```\n./bpm2fps.sh --help\nusage: cli.py [-h] [-s START] [-e END] [-b BPM] [-f FPS]\n\nbpm2fps - Match song beats to their closest frame.\n\noptions:\n  -h, --help            show this help message and exit\n  -s START, --start START\n                        Start time (seconds).\n  -e END, --end END     End time (seconds)\n  -b BPM, --bpm BPM     Beats per minute\n  -f FPS, --fps FPS     Frames per second\n```\n\n### Example\n```\n./bpm2fps.sh --bpm 120\n# Result:\n[\n  {\n    \"beat\": 0,\n    \"frame\": 0.0,\n    \"second\": 0.0\n  },\n  {\n    \"beat\": 1,\n    \"frame\": 12.0,\n    \"second\": 0.5\n  },\n  {\n    \"beat\": 2,\n    \"frame\": 24.0,\n    \"second\": 1.0\n  },\n  # ... and so on\n]\n```\n\nExample chained with ``jq`` to get only beat frames:\n```\n./bpm2fps.sh --bpm 120 | jq '.[][\"frame\"]'\n# Result:\n0\n12\n24\n36\n48\n60\n72\n84\n96\n108\n```\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Convert beats per minute to animation frames.",
    "version": "1.0.2",
    "project_urls": {
        "Homepage": "https://github.com/BreadMakesYouFull/bpm2fps.git"
    },
    "split_keywords": [
        "fps",
        "bpm",
        "calculate",
        "calculator",
        "usd",
        "animation",
        "anim",
        "reference"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "045a115b0cf88763f200069dc4d77aeab2d5b8ee49a7945b66ffd302fc886643",
                "md5": "63ae64b956c9298a44f52637ef617dca",
                "sha256": "d153a5a8927ba401a986739a02be8602c601422b5748ada52346be95863957d8"
            },
            "downloads": -1,
            "filename": "bpm2fps-1.0.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "63ae64b956c9298a44f52637ef617dca",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 8438,
            "upload_time": "2024-08-29T02:20:16",
            "upload_time_iso_8601": "2024-08-29T02:20:16.187037Z",
            "url": "https://files.pythonhosted.org/packages/04/5a/115b0cf88763f200069dc4d77aeab2d5b8ee49a7945b66ffd302fc886643/bpm2fps-1.0.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3f41913482070271b0f3630682702dcb583658560220b0e9f92fb9275c8a4381",
                "md5": "f839b7539b3d7b636ad394eff1728944",
                "sha256": "92aefc5f6320aca23be84845b155d7285603661063e5aa0f4b0e4cf8ef6a15d3"
            },
            "downloads": -1,
            "filename": "bpm2fps-1.0.2.tar.gz",
            "has_sig": false,
            "md5_digest": "f839b7539b3d7b636ad394eff1728944",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 8430,
            "upload_time": "2024-08-29T02:20:17",
            "upload_time_iso_8601": "2024-08-29T02:20:17.610941Z",
            "url": "https://files.pythonhosted.org/packages/3f/41/913482070271b0f3630682702dcb583658560220b0e9f92fb9275c8a4381/bpm2fps-1.0.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-08-29 02:20:17",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "BreadMakesYouFull",
    "github_project": "bpm2fps",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "bpm2fps"
}
        
Elapsed time: 0.48881s