Skip to content

feat: SG-44605: Optimize the loading and scrubbing of S3/Streaming media in RV - #1380

Open
deltag0 wants to merge 22 commits into
AcademySoftwareFoundation:mainfrom
deltag0:streamed-files
Open

feat: SG-44605: Optimize the loading and scrubbing of S3/Streaming media in RV#1380
deltag0 wants to merge 22 commits into
AcademySoftwareFoundation:mainfrom
deltag0:streamed-files

Conversation

@deltag0

@deltag0 deltag0 commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

feat: Optimize the loading and scrubbing of S3/Streaming media in RV

Summarize your change.

  • Updated FFMPEG 8 to 9
  • Added local caching for streamed media using the FFMPEG shared: protocol
  • Added background threads to open FFMPEG contexts for MovieReader clones since FFMPEG even if all the media is cached with FFFMPEG, it will try to establish a connection, which adds latency. If we do this process at the launch of RV, the latency is removed
  • Added background threads to start caching media over the internet in the background to optimize scrubbing further

Describe the reason for the change.

Previously, when media hosted on shotgrid was opened in OpenRV, to view a new file, there had to be a request made over the network, which was adding 1-2 seconds of latency every time a user jumped to a new file. This made scrubbing virtually impossible because of the delay. To improve this problem, the idea was to cache the media's raw bytes locally, so that RV can decode the bytes locally instead of having to establish a new HTTP connection for a new file. This would work, but would require us to manually jump to the new file for the caching to start. So, background threads to download every file were spawned.
I believe the number of threds for this process should be proportional to the amount of media the user loaded, as a lot of the time the threads should be inactive, waiting on the network.
Soon after, it was found that even if all media was cached before a user streams it on RV, scrubbing would still be painful because there were FFMPEG reader clones which had to establish their own connection, so they still added latency. To fix this, the connections were established at load time, with background threads, when the media is opened (after pre-loading).

Describe what you have tested and on which operating system.

  • Tested on a Mac
  • Viewed improvements that if files are cached locally, scrubbing is instant
  • Viewed that scrubbing with an empty cache with the Joyride media and 12 threads pre-fetching media allowed instant scrubbing in under 5 seconds
  • Big improvement from 12 threads pre-fetching media from 4

Add a list of changes, and note any that might need special attention during the review.

  • Verify update from FFMPEG 8 to 9

If possible, provide screenshots.

Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
@deltag0
deltag0 marked this pull request as draft August 17, 2026 20:12
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
@deltag0
deltag0 marked this pull request as ready for review August 19, 2026 15:36
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Signed-off-by: deltag0 <ioan.1931@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant