Repository navigation
cvcgl_volume_half_float: read the formats VTK asks for; skip GL's read-back where it reports 32F (macOS) - #1333
Merged
Merged
Conversation
… read-back where it reports 32F On macOS, under Apple's software renderer, the test counted 0 16F textures in both runs and aborted. The earlier diagnostic run (ci/full/volume-half-float-macos, 43781313300) listed every live texture there. The probe sees them all, and the volume's two tables (1024x1) are reported as R32F and RGB32F in the 16F run too. The 16F frame still differs from the 32F one by a little (mean 0.006, worst 1). That suggests the data was rounded to 16 bits and GL reports the 32F format, not that VTK asked for 32F. So the test now reads what VTK asks for where it asks: VTK's glad glTexImage2D pointer, swapped for a recorder once the window is initialised (VTK loads glad once per new context). It checks, on every desktop GL: * the 32F run asks for no 16F textures, and the 16F run asks for at least 2 (the tables); * GL keeps them as 16F (at least 2 alive, none in the 32F run), as before. The read-back is skipped only when GL reports none as 16F AND it keeps every texture asked for as 16F in the matching 32F format, and the skip names the renderer. Linux and Windows report 16F, so that check stays strict there. The probe clears stale GL errors first and looks up to name 4095, not 511. package-macos prints the test's lines from LastTest.log on every run, as for cvcgl_wake, so the skip and its reason show on a pass.
#1257's orthoslicer golden was made under llvmpipe, and PRs skip the macOS package jobs, so its first macOS run was the full push CI (44055940377). On all four macOS jobs, on every try, Apple's software renderer left 1149 px beyond +-40 (0.1662%, allowed 0.0020%), largest channel difference 187. The frames are the same picture: the nearest-sampled slices' texel edges and the volren's edges land a pixel apart. The four jobs' orthoslicer.actual.png are the same bytes (sha256 41d2760b...). That frame is committed as orthoslicer.macos.png, as docs/ARIADNE.md describes for widgets, scene and grid.
transfix
enabled auto-merge (squash)
November 19, 2026 00:27
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Makes
cvcgl_volume_half_float(from #1213) pass on the macOS package jobs, and says why when it skips the one check that can't be read there.What macOS showed
The test aborted on all four
package-macosjobs of master's full run 43813103811, with16F textures alive: 0 (32F run) vs 0 (16F run). An earlier diagnostic push (ci/full/volume-half-float-macos, run 43781313300) listed every live texture under Apple Software Renderer:R32F(0x822E) andRGB32F(0x8815), the same as in the 32F run.Reading VTK 9.5 found nothing Apple-specific in the path.
vtkSmartVolumeMapperpicks the GPU ray caster. The tables are created byCreate2DFromRawthroughvtkOpenGLState's format table duringRenderVolumetricGeometry. So the likely cause is that Apple's software renderer stores and reports a 16F texture in the matching 32F format, not that VolumeNode's switch fails. The new check below confirms or rules that out on the CI run itself.The change
glTexImage2D, by texture name. It swaps VTK's glad pointer, asgl_upload_counter.cppalready does in tests that pass on macOS. It does this afterrenderWindow()->Initialize(), because VTK loads glad once per new context.package-macosgets a step that prints the test's lines from LastTest.log on every run, likecvcgl_wake timings, so the skip and its reason show on a pass. Release jobs run ctest twice and the second run replaces LastTest.log, so only the Debug job shows them.Verified
cvcgl_volume_half_floatpasses on all fourpackage-macosjobs. The Debug job's new step prints:Also in this PR: a macOS golden for orthoslicer
The same run's other reds were not this change's, but they show on this PR because its checks attach to the same commit:
cvcgl_ari_goldenfailed on all four macOS jobs, on every try, at orthoslicer (from orthoslicer demo: three volume_slice planes beside a volren, a slice view down any axis (P7) #1257, never run on macOS before): 1149 px beyond +-40 (0.1662%, allowed 0.0020%). The frames are the same picture. The nearest-sampled slices' texel edges and the volren's edges land a pixel apart. The four jobs'orthoslicer.actual.pngare byte-identical, so 61c2217 commits that frame asorthoslicer.macos.png, as docs/ARIADNE.md describes for widgets, scene and grid.package-linux / libcvc-debug:cvcgl_ariadne_realizetimed out (300 s) three times on a slow runner. The median test there ran 2.8x slower than in the last good run (total 7750 s against about 2970 s), and the same test passed in 163 s onlibcvc-debug-grpcin the same run. That was a rerun, not a patch.cvcgl_terminal_sceneandcvcgl_lowmem_fastdraweach failed once on macOS and passed when ctest retried them.The branch now has master merged in (ee10e2c). It is pushed again as
ci/full/volume-half-float-askedto check the golden against current master on macOS.