Plugin API

Simple principle, add an API and plugin manager to allow plugins to be created for VEAI.

Doesn’t need to be complicated in my opinion, I’d be happy with just two methods in the API to start with:

void preProcessing(Bitmap map);
Where “map” is a pointer to the object holding the image for the frame about to be processed

void postProcessing(Bitmap map);
Where “map” is a pointer to the object holding the image for the frame after it has been run through the AI processing

The idea is that it will allow the plugin creator to edit the frame prior to AI enhancement (such as altering the colour profile etc…), and to alter or use the frame post enhancement (such as adding custom grain/noise, or saving frames/encoding to a file-type/encoding algorithm not currently supported by the main program such as AV1)

I feel having a basic API and a plugin system would allow people to create plugins for many of the simple suggestions on this feature request thread and would ultimately allow people to fine tune VEAI to their particular needs.

I would love to be able to just run the software via command line, but I guess that feature was removed long ago.

I think you have to look at this product from a financial perspective. Will they lose sales if they provide an API or plugin system? I can see someone using it on a large scale behind a website – perhaps that is why they took away the command line interface.

This is just me guessing, but I’ll bet it’s a lot harder to do with VEAI than other video processing programs. For the API function you ask for, it might be possible, but add lots of processing time. For example, you cannot process just one picture in VEAI. To do that, you need to copy the picture about 30 times.
This means, that VEAI always takes images in context of at least 30 images before or after the current image being processed. If you were to change that image at all during processing, who knows what it would do.

1 Like

With regards to my suggestion for an API I was simply suggesting a basic API to allow pre and post processing of frames; at the end of the day it would be up to the Devs to decide which functions to put into the API based on what they felt would be useful and would not compromise their business model.

The two functions I suggested would not mean the program could be run from the command line as the user would still have to manually choose the input file and press start. Those API functions would just allow some basic pre and post processing - which, with well made plugins, could save people a lot of time when restoring old video.

Hmm yes with VEAI presumably running a LSTM-NN it does complicate things to some extent; however the frame still has to be loaded into memory from the source file at some-point which seems an ideal time to perform the pre-processing on the frame. Presumably the frames are then reused from memory rather than being reloaded from disk everytime they are put through the NN with the nearby frames. Therefore if the post-processing function was called on the frame just after loading it from disk the function would only need to be run once per frame (thus in linear time) which should not add much overhead (obviously depending on what the plugins go on to do with the function).
Post-processing could be applied right before the frame is written to file or added to the encoder (if using the x264 encoder) again only needing to be applied once per frame so should also run in linear time.
Depending on how the internal functions of VEAI work I can’t think these two functions should be too hard to implement as they are implented straight after loading from file and writing to file.