添加处理音频窗口大小的功能,支持动态调整插件宿主窗口尺寸

This commit is contained in:
daiqingshuang
2025-08-14 17:58:45 +08:00
parent 487013cc68
commit 6476ad1c5b

View File

@@ -42,6 +42,14 @@ inline VstIntPtr VSTCALLBACK host_callback(AEffect* effect,
case audioMasterGetInputLatency: case audioMasterGetInputLatency:
case audioMasterGetOutputLatency: case audioMasterGetOutputLatency:
return 0; return 0;
case audioMasterSizeWindow: {
const auto width = static_cast<int32_t>(index);
const auto height = static_cast<int32_t>(value);
if (window_handle) {
glfwSetWindowSize(window_handle, width, height);
}
return 1;
}
/* -------- 显示刷新 -------- */ /* -------- 显示刷新 -------- */
case audioMasterUpdateDisplay: case audioMasterUpdateDisplay: