Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for writing PNG files to shared volumes #15

Open
yondonfu opened this issue Jan 29, 2024 · 0 comments
Open

Add support for writing PNG files to shared volumes #15

yondonfu opened this issue Jan 29, 2024 · 0 comments

Comments

@yondonfu
Copy link
Member

At the moment, the runner app routes return images as base64 encoded data URLs. This can be convenient if the response to a user is meant to be a base64 encoded image. But, this is inefficient due to the base64 encoding particularly if there are many images being transmitted which is the case for image-to-video which returns multiple frames of a video as PNG files - this inefficiency is amplified in the image-to-video case because go-livepeer will decode the data URLs and write the PNG files to disk in order use the ffmpeg image2 demuxer so that go-livepeer can encode the PNG files into a video.

There should be an option for the runner app routes to write images to an output directory of a shared volume that go-livepeer can then read from. This can be the default behavior for the image-to-video route. The default behavior for the routes that return single images can still be to return base64 encoded data URLs, but there can be an option to change this. go-livepeer's APIs would allow callers to request an HTTP URL served by the node's object store and the runner API would allow callers to request a file:// URL served by the shared storage for the runner app.

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

No branches or pull requests

1 participant