Overview
DigitalZoom C++ library implements digital zoom using bicubic interpolation provided by the ImageResizer module (SIMD-optimized, no external dependencies). The library supports digital zoom level from x1 to x20. The library depends on VFilter library (provides interface for video filter, source code included, Apache 2.0 license) and ImageResizer library (source code included). The library doesn’t have third-party dependencies to be installed in OS. Additionally test application depends on OpenCV library (version >= 4.5, linked, Apache 2.0 license) to provide user interface. The library uses C++17 standard.
Documentation
Documentation: GO TO DOCUMENTATION
Simple interface
namespace cr
{
namespace video
{
/// Digital zoom class.
class DigitalZoom : public VFilter
{
public:
/// Get the version of the DigitalZoom class.
static std::string getVersion();
/// Initialize digital zoom.
bool initVFilter(VFilterParams& params) override;
/// Set digital zoom parameter.
bool setParam(VFilterParam id, float value) override;
/// Get the value of a specific VFilter parameter.
float getParam(VFilterParam id) override;
/// Get the structure containing all VFilter parameters.
void getParams(VFilterParams& params) override;
/// Execute a VFilter action command.
bool executeCommand(VFilterCommand id) override;
/// Process frame (Perform digital zoom).
bool processFrame(cr::video::Frame& frame) override;
/// Set mask for filter.
bool setMask(cr::video::Frame mask) override;
/// Decode and execute command.
bool decodeAndExecuteCommand(uint8_t* data, int size) override;
};
}
}

