Files
fn_registry/dev/issues/0049b-cpp-bump-gl-43.md
T
egutierrez 7c09255c8a chore(issues): plan 0049 OSINT graph viewer multi-issue
Aggregates the planning artifacts for the 0049 series (umbrella + 0049a..0049k):

- New rule cpp_apps.md (registered in INDEX) — standardize structure, CMake
  patterns, app.md frontmatter and sub-repo for C++ apps; points to the
  authoritative cpp/PATTERNS.md and cpp/DESIGN_SYSTEM.md.
- Feature flag osint_graph_v1 (disabled until 0049k closes).
- Issue 0049 (umbrella) and sub-issues 0049b..0049k describing the GPU
  rendering system, force-layout, types, sources, labels and the final
  graph_explorer app integration.
- README updated with the new rows (all pending; 0049a will flip to
  completed in the next commit).
2026-04-29 21:08:36 +02:00

3.3 KiB

0049b — Bump OpenGL 3.3 → 4.3 core en cpp/framework

Metadata

Campo Valor
ID 0049b
Estado pendiente
Prioridad alta
Tipo infraestructura — parte de #0049

Dependencias

Bloqueada por: ninguna (ortogonal a 0049a). Desbloquea: 0049h (compute shaders necesitan 4.3) y simplifica 0049f.


Objetivo

Subir el contexto OpenGL del framework de 3.3 core a 4.3 core para habilitar compute shaders, SSBOs, e image load/store. Verificar que las 4 apps C++ existentes siguen funcionando.

Contexto

Hoy cpp/framework/app_base.cpp pide GL 3.3 core (glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3); MINOR, 3). Limita el renderer GPU del grafo: sin compute, sin SSBO, sin atomic counters. Subir a 4.3 es un cambio de una sola linea en el shell pero requiere validar que ningun shader del registry usa caracteristicas removidas (no las hay — 4.3 core es superset compatible) y que ningun driver target falla.

Arquitectura

cpp/framework/
└── app_base.cpp                # MOD: GL_CONTEXT_VERSION_MAJOR/MINOR → 4/3

Posible adaptacion en cpp/functions/gfx/gl_loader.cpp si los punteros 4.3 no estan cargados (revisar).

Tareas

Fase 1 — Cambio

  • 1.1 En app_base.cpp, cambiar:
    glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 4);
    glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 3);
    glfwWindowHint(GLFW_OPENGL_PROFILE,        GLFW_OPENGL_CORE_PROFILE);
    glfwWindowHint(GLFW_OPENGL_FORWARD_COMPAT, GL_TRUE);
    
  • 1.2 En gl_loader.cpp, anadir punteros 4.x usados por sub-issues posteriores (compute, SSBO, atomic counter). Solo declarar los que se vayan a usar — no inundar.

Fase 2 — Verificacion en apps existentes

  • 2.1 Linux native build: cmake --build cpp/build/linux --target shaders_lab registry_dashboard primitives_gallery chart_demo -j$(nproc). Cero warnings nuevos.
  • 2.2 Run de cada app y captura visual basica (shaders_lab abre canvas, dashboard carga datos, primitives_gallery navega demos, chart_demo renderiza).
  • 2.3 Windows cross-compile: cmake --build cpp/build/windows .... Mismas apps, mismo check.

Fase 3 — Tests visuales

  • 3.1 Regenerar goldens: cpp/scripts/update_goldens.sh.
  • 3.2 cpp/scripts/run_tests.sh debe terminar verde — incluye test_visual con tolerancia 1%.
  • 3.3 Revisar diffs en goldens: si cambia algo > tolerancia, investigar (deberia ser idempotente al subir version).

Fase 4 — Cleanup

  • Commit en master: feat(framework): bump OpenGL 3.3 → 4.3 core context.
  • Verificar que apps_tbd.md se respeta (rama corta, merge --no-ff a master).

Criterio de done

  • Las 4 apps existentes compilan en Linux y Windows.
  • cpp/scripts/run_tests.sh verde.
  • glGetString(GL_VERSION) reporta 4.3+ en runtime.

Riesgos

Riesgo Mitigacion
HW de pruebas no soporta 4.3 Toda GPU ~2012+ lo soporta; WSL Mesa software soporta 4.3+
Cambio de profile rompe alguna deprecation 4.3 core ya excluye fixed-function igual que 3.3 core; no hay regresion esperable
Visual goldens cambian por driver Aceptar regenerar; si diff es semantico, investigar shader