build/ci: green builds and tests on all three platforms

Compiler hygiene (all platforms):
- Silence warnings across the tree: missing override, -Wreorder ctor
  init, -Wshadow, -Wsign-compare, missing switch cases, unused
  functions/captures, Qt 6.11 deprecations (QMouseEvent/QDropEvent
  accessors, qAsConst, Q_FOREACH over non-shared containers,
  AA_UseHighDpiPixmaps) and the .bak/ backup tree removal.
- Fix regressions from the cleanup: missing clip decls in
  capi/timeline.cpp, plugin.cpp rename fallout, panel setFocus
  ambiguity, QGraphicsItem::pos vs event->position(), duplicate
  k_push_button case, boolean test variable.

Windows:
- Qt portability: CommandLineParser is_set/add_option, QTimeZone
  systemTimeZone (QTimeZone::LocalTime is 6.11-only), k_progress_* enum.
- Linking: stop adding oakengine to OLIVE_LIBRARIES (import lib plus
  oakengine-obj caused multiple definitions); add OAKENGINE_STATIC so
  internal consumers no longer reference __imp_* stubs.
- oakengine.ver: export olive::Renderer typeinfo so liboakgl.so can be
  dlopened (Linux), DynamicRenderer no longer dlcloses backend libraries
  (crash in RenderManager's dtor calling into unmapped memory).
- OTIO runtime: copy DLLs next to every binary on Windows instead of
  relying on PATH (0xc0000135 in gtest discovery).
- Headless GL: the runner only has GDI OpenGL 1.1, killing every render
  worker. Deploy Mesa llvmpipe as opengl32sw.dll (Qt's software-GL
  channel) with QT_OPENGL=software, and let QT_OPENGL override the
  AA_UseDesktopOpenGL default. ExportTask fails fast after 8 consecutive
  undelivered frames instead of segfaulting or grinding forever;
  FFmpegEncoder::write_frame tolerates null frames.
- Tests: GetTempPathA+PID temp dirs, GetLongPathNameA for 8.3 names,
  forward-slash normalization when comparing project filenames.

Linux:
- Install libshaderc-dev so oakvulkan compiles GLSL (Vulkan tests).
- Accept UNORM floor-or-round (63/64) in the blit ping-pong test.
- Skip MainWindow construction test on the offscreen QPA (cannot paint
  QOpenGLWidget).

Also: oak_cli_transcode gets a 300s ctest timeout, worker logs GL
context version and LoadGraph/render_frame stages, and
docs/plans/eliminate-event-bridge-issues.md (English translation).
This commit is contained in:
2026-08-04 21:34:31 +08:00
parent 5006382790
commit 712badbaa7
127 changed files with 826 additions and 8498 deletions
+18 -17
View File
@@ -19,6 +19,7 @@
***/
#include <utility>
#include "nodeview.h"
#include <QInputDialog>
@@ -75,8 +76,8 @@ NodeView::NodeView(QWidget *parent)
, overlay_view_(nullptr)
, scale_(1.0)
, dont_emit_selection_signals_(false)
, show_in_param_editor_action_(nullptr)
, bridge_(new EngineEventBridge(this))
, show_in_param_editor_action_(nullptr)
{
setScene(&scene_);
set_default_drag_mode(RubberBandDrag);
@@ -499,7 +500,7 @@ void NodeView::set_color_label(int index)
// WRAPPER-GAP: oakengine_undo_* command assembly (no wrapper)
void *command = oakengine_undo_command_create_multi();
for (const oak::Node &node : qAsConst(selected_nodes_)) {
for (const oak::Node &node : std::as_const(selected_nodes_)) {
oakengine_undo_command_multi_add_child(
command,
oakengine_node_set_color_label_command(node.handle(), index));
@@ -528,8 +529,8 @@ void NodeView::keyPressEvent(QKeyEvent *event)
case Qt::Key_Down: {
// WRAPPER-GAP: oakengine_undo_* command assembly (no wrapper)
void *pos_command = oakengine_undo_command_create_multi();
for (const oak::Node &n : qAsConst(selected_nodes_)) {
for (const oak::Node &context : qAsConst(contexts_)) {
for (const oak::Node &n : std::as_const(selected_nodes_)) {
for (const oak::Node &context : std::as_const(contexts_)) {
QPointF old_pos;
bool old_expanded = false;
if (context.context_position_of(n, &old_pos, &old_expanded)) {
@@ -595,7 +596,7 @@ void NodeView::mousePressEvent(QMouseEvent *event)
return;
// Get the item that the user clicked on, if any
QGraphicsItem *item = itemAt(event->pos());
QGraphicsItem *item = itemAt(event->position().toPoint());
if (event->button() == Qt::LeftButton) {
// Sane defaults
@@ -657,7 +658,7 @@ void NodeView::mousePressEvent(QMouseEvent *event)
scene_.addItem(create_edge_);
// Position edge to mouse cursor
position_new_edge(event->pos());
position_new_edge(event->position().toPoint());
return;
}
}
@@ -698,7 +699,7 @@ void NodeView::mouseMoveEvent(QMouseEvent *event)
return;
if (create_edge_) {
position_new_edge(event->pos());
position_new_edge(event->position().toPoint());
return;
}
@@ -708,7 +709,7 @@ void NodeView::mouseMoveEvent(QMouseEvent *event)
// See if there are any items attached
if (!attached_items_.isEmpty()) {
process_moving_attached_nodes(event->pos());
process_moving_attached_nodes(event->position().toPoint());
}
}
void NodeView::mouseReleaseEvent(QMouseEvent *event)
@@ -729,11 +730,11 @@ void NodeView::mouseReleaseEvent(QMouseEvent *event)
bool had_attached_items = !attached_items_.isEmpty();
if (!attached_items_.isEmpty()) {
select_context = get_context_at_mouse_pos(event->pos());
select_context = get_context_at_mouse_pos(event->position().toPoint());
if (!select_context.is_null()) {
select_nodes = process_dropping_attached_nodes(command, select_context,
event->pos());
event->position().toPoint());
} else {
QToolTip::showText(QCursor::pos(),
tr("Nodes must be placed inside a context."));
@@ -780,7 +781,7 @@ void NodeView::mouseDoubleClickEvent(QMouseEvent *event)
if (!(event->modifiers() & Qt::ControlModifier)) {
NodeViewItem *item_at_cursor =
dynamic_cast<NodeViewItem *>(itemAt(event->pos()));
dynamic_cast<NodeViewItem *>(itemAt(event->position().toPoint()));
if (item_at_cursor) {
item_at_cursor->toggle_expanded();
}
@@ -841,9 +842,9 @@ void NodeView::dragMoveEvent(QDragMoveEvent *event)
if (attached_items_.empty()) {
event->ignore();
} else {
process_moving_attached_nodes(event->pos());
process_moving_attached_nodes(event->position().toPoint());
if (get_context_at_mouse_pos(event->pos())) {
if (get_context_at_mouse_pos(event->position().toPoint())) {
event->accept();
} else {
event->ignore();
@@ -853,12 +854,12 @@ void NodeView::dragMoveEvent(QDragMoveEvent *event)
void NodeView::dropEvent(QDropEvent *event)
{
oak::Node drop_ctx = get_context_at_mouse_pos(event->pos());
oak::Node drop_ctx = get_context_at_mouse_pos(event->position().toPoint());
if (!drop_ctx.is_null()) {
// WRAPPER-GAP: oakengine_undo_* command assembly (no wrapper)
void *command = oakengine_undo_command_create_multi();
QVector<oak::Node> select_nodes =
process_dropping_attached_nodes(command, drop_ctx, event->pos());
process_dropping_attached_nodes(command, drop_ctx, event->position().toPoint());
oakengine_undo_push(
command, tr("Dropped %1 Node(s)").arg(select_nodes.size()).toUtf8().constData());
@@ -1192,7 +1193,7 @@ void NodeView::move_attached_nodes_to_cursor(const QPoint &p)
{
QPointF item_pos = mapToScene(p);
for (const AttachedItem &i : qAsConst(attached_items_)) {
for (const AttachedItem &i : std::as_const(attached_items_)) {
if (i.item) {
i.item->setPos(item_pos + i.original_pos);
}
@@ -1219,7 +1220,7 @@ void NodeView::process_moving_attached_nodes(const QPoint &pos)
NodeViewEdge *new_drop_edge = nullptr;
// See if there is an edge here
for (QGraphicsItem *item : qAsConst(items)) {
for (QGraphicsItem *item : std::as_const(items)) {
new_drop_edge = dynamic_cast<NodeViewEdge *>(item);
if (new_drop_edge) {
+2 -2
View File
@@ -118,8 +118,8 @@ NodeViewItem::NodeViewItem(oak::Node node, const QString &input,
bridge_->subscribe(node_.handle(), OAKENGINE_EVENT_NODE_INPUT_ARRAY_SIZE_CHANGED);
connect(bridge_, &EngineEventBridge::node_input_array_size_changed, this,
[this](OakEngineNode *, const QString &input, int, int) {
input_array_size_changed(input);
[this](OakEngineNode *, const QString &changed_input, int, int) {
input_array_size_changed(changed_input);
});
}