feat(render): dynamic OpenGL/Vulkan backend split and backend-neutral viewer

- Extract libolive-rendercore static library to minimize backend link boundary.
- Add DynamicRenderer adapter with C ABI (oakgl/oakvulkan shared libs).
- Make OAK_ENABLE_DYNAMIC_RENDER_BACKEND default ON with OpenGL fallback.
- Implement VulkanRenderer prototype (textures, shaders, UBO blit, readback).
- Add backend-neutral viewer readback path (offscreen -> QImage -> QPainter).
- Refactor PluginRenderer to be renderer-agnostic; OFX plugins fall back to CPU
  path on non-OpenGL backends while preserving OpenGL render path.
- Add Renderer::AttachOutputTexture/DetachOutputTexture and C ABI forwards.
- Update docs/zh/render-backend-dynamic-plan.md for Phase 3/4/5.
This commit is contained in:
2026-07-13 10:19:29 +08:00
parent 5fc8232671
commit 225f8505c2
42 changed files with 3042 additions and 495 deletions
+12
View File
@@ -29,6 +29,7 @@ extern "C" {
#include <QtMath>
#include "core.h"
#include "ofxImageEffect.h"
namespace olive
{
@@ -120,6 +121,17 @@ VideoParams::VideoParams(int width, int height, int depth, PixelFormat format,
set_defaults_for_footage();
}
void VideoParams::set_channel_count(const std::string &ofxComponent)
{
if (ofxComponent == kOfxImageComponentAlpha) {
channel_count_ = 1;
} else if (ofxComponent == kOfxImageComponentRGB) {
channel_count_ = kRGBChannelCount;
} else if (ofxComponent == kOfxImageComponentRGBA) {
channel_count_ = kRGBAChannelCount;
}
}
VideoParams::VideoParams(int width, int height, const rational &time_base,
PixelFormat format, int nb_channels,
const rational &pixel_aspect_ratio,