Skip to content
cgwirePublic

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

1 watching

Forks

Latest commit

 

History

32 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OpenRV Kitsu integration

This OpenRV package connects RV to Kitsu. It adds a Kitsu Review panel below the RV viewport. Use this panel to review revisions, write comments and sync annotations in the two directions.

Features

Login

  • Log in with your Kitsu server URL, email and password.
  • Remember me keeps you logged in between OpenRV sessions. The plugin keeps the Kitsu session token in the credential store of your system: macOS Keychain, Windows Credential Manager, or Secret Service and KWallet on Linux. It never saves your password.
  • Log Out removes the saved session and revokes it on the server.
  • The plugin always keeps the server URL and the email, also without keyring.
  • The plugin refreshes expired access tokens automatically.

Find revisions to review

  • Playlists tab: the playlists of your open productions. The most recent playlist is first.
    • The tab shows only the playlists with a task in a feedback-request status, such as WFA. Tick Show all playlists to show all the playlists.
    • Each playlist shows a "To review" count. The count is an estimate (~) until you open the playlist.
    • The tab marks client playlists with (client).
  • My Checks tab: the latest revision of each of your tasks.
  • Each revision shows a thumbnail, the shot (SEQ / SHOT in playlists), the task type, the revision number, the status and the date. Revisions that wait for review are in bold, in the Kitsu color of their status.

Review

  • Download + Load in RV downloads the preview (movie or still image) to ~/kitsu_review_downloads. Then it adds the preview to the RV session, with the annotations that Kitsu stores for it.
  • RV plays at the frame rate of the production in Kitsu, or at 24 fps if the production has no frame rate. Thus, RV frames and Kitsu frames are the same.
  • The panel shows the comment history of the task. Each comment shows the status it set.
  • Add Comment posts a comment, with or without a status change. The status list shows only the statuses that your role and the production allow. You can post a status change without text, as in Kitsu.

Annotations

Draw with the RV Paint tools, then click Export to Kitsu. The conversion works in the two directions for these tools:

OpenRV Kitsu
Pen (with pressure) Brush stroke
Ellipse Circle / ellipse
Rectangle Rectangle
Arrow Arrow
Text (bold, italic, underline, multi-line) Text
Eraser Eraser
  • Export reads the strokes of all the paint nodes that draw on the source of the revision. This includes the sequence-level paint nodes that RV uses in a sequence view.
  • Unchanged annotations keep their Kitsu id, author and timestamps. Export sends changed annotations as updates and new annotations as additions.
  • In RV, an eraser removes all the strokes drawn before it. In Kitsu, each object has its own eraser paths. The plugin converts between the two models, so erased strokes look the same on the two sides.

Dev tab

This tab shows the annotations at the playhead as JSON, to debug the conversion:

  • the OpenRV paint properties,
  • the same properties in Kitsu format (the data that Export sends),
  • the data that Kitsu stores for the selected revision.

The tab can refresh every second and copy the JSON to the clipboard.

Limitations

  • RV cannot rotate ellipses, rectangles and text. The plugin ignores the rotation from Kitsu.
  • RV does not get the rounded corners of rectangles or the arrow head size from Kitsu.
  • RV draws text in its default font, aligned left, without the Kitsu background box.
  • RV has no equivalent for the Kitsu "restore" (inverted) eraser. The plugin ignores it.
  • You cannot erase Kitsu text.
  • The plugin does not load Kitsu lines into RV.

Installation

1. Install the Python dependencies

The plugin runs in the Python interpreter of OpenRV, not in the Python of your system. Install gazu and requests in this interpreter. keyring is optional: without it, Remember me is disabled.

# Linux and Windows: the interpreter is in the bin folder of OpenRV
$OPENRV_PATH/_build/stage/app/bin/python3 -m pip install gazu requests keyring

# macOS: the interpreter is in the app bundle
/Applications/OpenRV.app/Contents/MacOS/python3 -m pip install gazu requests keyring

Change the path to the OpenRV location on your computer. To check the installation, run:

<openrv-python> -c "import gazu, requests"

On Linux, keyring needs a running Secret Service (GNOME Keyring) or KWallet.

2. Install the package

  1. Download kitsu-<version>.rvpkg from the Releases page.
  2. In OpenRV, open Preferences > Packages, click Add Packages and select the file.
  3. Tick the Installed and Load boxes of the Kitsu package, then restart OpenRV.

You can also use the OpenRV command line:

$OPENRV_PATH/_build/stage/app/bin/rvpkg -add $HOME/.rv/Packages kitsu-<version>.rvpkg
$OPENRV_PATH/_build/stage/app/bin/rvpkg -install $HOME/.rv/Packages/kitsu-<version>.rvpkg

To update, remove the old version in Preferences > Packages, then add the new version.

3. Open the panel

Select Kitsu Review > Toggle Review Panel, then log in with your Kitsu server URL, email and password.

Development

The plugin has these modules:

  • kitsu.py: the panel and the RV mode that docks it.
  • kitsu_review_model.py: the Kitsu (gazu) calls and the status rules.
  • kitsu_session_store.py: the saved session (QSettings and the credential store).
  • kitsu_rv_session.py: the RV sources, and the read and write operations on paint nodes.
  • kitsu_review_log.py: the log messages.
  • annotation_converter.py: the Kitsu ↔ OpenRV annotation conversion. It uses only the Python standard library.

To make and install a local package:

zip -r kitsu-1.0.rvpkg ./src/PACKAGE ./src/*.py

$OPENRV_PATH/_build/stage/app/bin/rvpkg -uninstall $HOME/.rv/Packages/kitsu-1.0.rvpkg -force
$OPENRV_PATH/_build/stage/app/bin/rvpkg -remove $HOME/.rv/Packages/kitsu-1.0.rvpkg -force
$OPENRV_PATH/_build/stage/app/bin/rvpkg -add $HOME/.rv/Packages PACKAGE_PATH/kitsu-1.0.rvpkg
$OPENRV_PATH/_build/stage/app/bin/rvpkg -install $HOME/.rv/Packages/kitsu-1.0.rvpkg

Convert annotations outside OpenRV

annotation_converter.py also runs as a command. Use it to test the conversion on a Kitsu annotation dump:

python src/annotation_converter.py annotations.json --width 1920 --height 1080 --fps 24 -o shapes.json

Use --help to see all the options: canvas size, frame offset, frame base and default frame for stills.

TODO

  • Load Kitsu lines into RV.
  • Keep the rotation of ellipses, rectangles and text.

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages