19 Commits

Author SHA1 Message Date
L'électron rare d8aa727887 feat: add counter-rotating wireframe shells
Layer E draws two concentric wireframe shells of the sphere with
additive blending: an outer blue shell breathing with bass and an
inner magenta shell pulsing with kick, spinning opposite ways.
2026-05-18 19:13:11 +02:00
L'électron rare 914e52deaf feat: add toggleable wireframe layer
A fourth layer draws the icosphere as a wireframe, displaced by the
same relief and rendered as bright unlit colormap lines just above
the skin. Toggled with key 4.
2026-05-18 18:43:31 +02:00
L'électron rare 7fc4f41f4e feat: 3D relief, lighting and reactive motion
The spectrogram now extrudes the geometry alongside the waveform, the
skin is lit with a screen-space normal, and the sphere tumbles and
pulses with the kick and signal energy.
2026-05-18 18:39:14 +02:00
L'électron rare e33375f7ac fix: render point cloud as real GL points
drawVertices on the indexed skin mesh gave a degenerate gl_PointCoord,
so the round-point discard killed every fragment. Use a dedicated
OF_PRIMITIVE_POINTS mesh, float it 5% outside the skin, enlarge points.
2026-05-18 18:05:50 +02:00
L'électron rare e06f53b11e fix: pause sphere auto-rotation while dragging
Auto-rotation ran unconditionally, so it kept spinning during a
camera-orbit drag. Accumulate a frame-rate-independent angle only
when the mouse is not pressed.
2026-05-18 17:48:10 +02:00
L'électron rare 94124f974e docs: document oscope-sphere project
Add the project CLAUDE.md and README covering the build, the stereo
channel convention, the three layers, controls, and the 16 MS/s
dual-channel hardware constraint.
2026-05-18 17:38:16 +02:00
L'électron rare 30fa7276c8 refactor: share sphere shader uniform binding
drawSkin and drawPoints duplicated six uniform-setup lines. Extract
them into a private bindUniforms helper so future uniforms are added
in one place.
2026-05-18 17:36:37 +02:00
L'électron rare a8be68adff feat: add point-cloud sphere layer
Render the icosphere vertices as rounded points sharing the skin's
displacement and colormap, switched by a renderMode uniform and
toggled with key 3.
2026-05-18 17:32:29 +02:00
L'électron rare 9b82a90579 feat: add stereo waveform orbit rings
Two perpendicular line-loop rings orbit the sphere, the blue ring
modulated by CH1 and the orange ring by CH2, toggled with key 2.
2026-05-18 17:27:07 +02:00
L'électron rare eeb5726103 feat: displace sphere with live waveform
Upload the per-channel waveform as a texture and displace icosphere
vertices radially in the vertex shader: CH1 drives the northern
hemisphere, CH2 the southern.
2026-05-18 17:22:19 +02:00
L'électron rare 4cca03db9f fix: log sphere shader load failure
ofShader::load returned bool was discarded, so a failed shader load
rendered black with no diagnostic. Log an error on failure and
document the global ofDisableArbTex state change.
2026-05-18 17:19:25 +02:00
L'électron rare fddb31e3ee feat: render spectrogram sphere skin
Context: Task 5 of oscope-sphere - add the SphereViz layer A skin
and full ofApp wiring so the app produces a visual output.

Approach: Build an icosphere (5 subdivisions) skinned by a scrolling
2-channel spectrogram texture uploaded each frame via ofFloatPixels.
GLSL 150 shaders compute spherical UV from vertex direction so the
texture wraps seamlessly; scroll is handled by a fract() offset in
the fragment shader to avoid re-uploading geometry.

Changes:
- bin/data/shaders/sphere.vert: spherical UV projection from position
- bin/data/shaders/sphere.frag: magma/viridis colormaps + scroll
- src/SphereViz.h/.cpp: icosphere mesh, shader, texture management,
  pushSpectrogramColumn() wraps SpectrogramBuffer for dual-channel
- src/ofApp.h: full member declarations (camera, analyzers, flags)
- src/ofApp.cpp: setup/update/draw/HUD/keyPressed wired end-to-end;
  HantekDevice probed at startup, falls back to DemoSignal on failure

Impact: app renders a rotating spectrogram globe in demo mode with
orbit camera, colormap toggle, freeze, and per-layer visibility keys.
2026-05-18 17:12:19 +02:00
L'électron rare 04fb49aae3 chore: ignore openframeworks info.plist artifact
The openFrameworks build auto-generates openFrameworks-Info.plist at
the project root. It is a build artifact, not a source file.
2026-05-18 17:09:04 +02:00
L'électron rare 921ae9cd42 build: add openFrameworks app skeleton
Copy oscope-of's Makefile and libusb-aware config.make, add a window
bootstrap and a placeholder ofApp so the GL build is verified before
any feature code lands.
2026-05-18 17:05:44 +02:00
L'électron rare f79ce95f78 test: verify demo signal phase continuity
The old test only checked two blocks differ, true of any non-DC
signal. Replace it with a split-equals-whole identity that genuinely
proves next() is deterministic and continuous across call boundaries.
2026-05-18 16:14:08 +02:00
L'électron rare 9fd856744d feat: add synthetic demo signal source
Pure-C++ continuous two-channel generator used when no scope is
connected: CH1 frequency sweep, CH2 steady tone plus noise. Adds the
run_tests.sh runner covering all three pure-C++ units.
2026-05-18 16:10:24 +02:00
L'électron rare 549a6b53a6 fix: guard spectrogram buffer against height=2
A buffer of height 2 made half-1 zero, dividing by zero in pushColumn
and writing NaN into the column. Clamp the denominator and add a
regression test for the 2-row case.
2026-05-18 16:07:31 +02:00
L'électron rare b8d76ccb27 feat: add rolling spectrogram column buffer
Pure-C++ store that log-resamples both channels' FFT magnitudes into
scrolling columns, CH1 north and CH2 south, high frequencies toward
the poles. No GL dependency, fully unit-tested.
2026-05-18 16:03:29 +02:00
L'électron rare 1848368bc2 build: scaffold oscope-sphere project
Context: oscope-sphere is a new openFrameworks app (sibling of
oscope-of) that will render audio analysis on a 3D sphere. This
commit establishes the project tree and reuses the mature capture
and analysis layer from oscope-of.

Approach: Copy four proven source files byte-for-byte from
oscope-of/src/ (no modifications), create the standard oF directory
layout, and add a standalone clang++ test harness that validates two
design assumptions without requiring openFrameworks installed.

Changes:
- Create oscope-sphere/{src,tests,bin/data/shaders} directories
- Copy FFT.h/cpp, AudioAnalyzer.h/cpp, ScopeData.h,
  HantekDevice.h/cpp from oscope-of/src (unmodified)
- Add addons.make and .gitignore for oF build system
- Add tests/check.h: lightweight CHECK/REPORT macros
- Add tests/test_analysis.cpp: two tests (FFT peak at bin 64,
  per-channel isolation via dual-analyzer trick)

Impact: Test harness compiles with plain clang++ -std=c++17 and
passes 5/5 checks, confirming FFT correctness and AudioAnalyzer
channel isolation before any oF integration work begins.
2026-05-18 15:58:14 +02:00