ffmpeg on google app engine or other alternatives
This isn’t really a problem with any specific bit of code more just a general question about how I would host a ffmpeg function within a severless function like google app engine. Basically I have a block of code that takes every n frame a video and uploads it to google cloud storage. I have tried implementing such a solution with Firebase functions but to no avail. I think the primary problem is really to do with file storage, from my undetnsdjng data should be written to the tmp folder.
So if anyone can outline exactly how I could host this on app engine that would be great, please be very specific and don’t assumeI know anything because I’ve only really worked with functions :)
Thanks so much
//Essentially this but on app engine or any other severle开发者_如何学编程ss environment
try {
const process = new ffmpeg('star_wars_film_scene.mp4');
process.then(function(video) {
// Callback mode
video.fnExtractFrameToJPG('helpers/frames/', {
every_n_frames: 500
}, function(error, files) {
if (error) {
console.log(error);
return;
}
ProcessFrames(files);
});
}, function(err) {
console.log(err);
});
} catch (e) {
console.log('Houston, we have a problem')
console.log(e.code);
console.log(e.msg);
}
精彩评论