ggseg.meshes (development version)
Breaking changes
- Cortical coordinates are FreeSurfer’s native axes:
xleft-right,yanterior-posterior,zsuperior-inferior. They were stored rotated 90 degrees, andggseg3drotated them back, so the pair was a round trip to identity for the only consumer there was. Code reading these meshes directly and relying on the rotated convention needs its axes swapped: oldxis nowy, oldyis now-x. Faces are unchanged, so atlas vertex indices still address the same vertices.
New features
Every mesh carries a
ggseg.formats::mesh_space()recording its vertex space, hemisphere, whether the coordinates are anatomical and the mapping to MNI305, so a consumer places a point from what the mesh says rather than from which package it came from.pial,white,smoothwm,origandmidthicknessmap to MNI305 by the identity;semi-inflatedandsphererecord no mapping, every vertex having been moved.Surfaces are read through
ggseg.extra::read_surface_mesh(), so the ecosystem decides in one place how to read a surface and what its faces count from.save_sysdata()now refuses a mesh that records no frame, or an anatomical one with no mapping.Vignette figures and the package logo are written as 8-bit palette PNGs, and the logo is additionally resized to its display size, cutting the source tarball from 5.3 MB to under 2.5 MB and back below the CRAN 5 MB limit. The figures are unchanged in size and content.
Documented that the cortical face table matches the ggseg.formats inflated mesh in connectivity but not in index base: it is 1-based, that one 0-based.
Corrected
get_cerebellar_flatmap()’s documentation: the flatmap is the first 28,935 vertices of the 30,013-vertex SUIT 3D pial surface, not a vertex-for-vertex match, and itszis exactly zero.face_index_baseis now verified against the stored faces instead of being stamped on as a literal; an inconsistent mesh errors rather than shipping a wrong attribute.The
data-raw/scripts now sharedata-raw/save_sysdata.R, so re-running either one can no longer drop the other’s meshes fromR/sysdata.rda.Recorded the remaining
data-raw/dependencies inConfig/Needs/data-raw.Dropped
ggseg.formatsfromSuggests; it was referenced only in prose.Moved
freesurfer,freesurferformatsandgiftifromSuggeststoConfig/Needs/data-raw, and recordedmagickthere too. All four are used only by the mesh- and figure-building scripts indata-raw/, which is not part of the built package, so checking or installingggseg.meshesno longer asks for them.Documentation is regenerated with roxygen2 8.1.0, matching the rest of the ggsegverse packages.
ggseg.meshes 0.0.1
CRAN release: 2026-04-09
New features
- Cortical fsaverage5 surfaces: pial, white, midthickness, semi-inflated, sphere, smoothwm, orig
- SUIT cerebellar flatmap surface
-
get_cortical_mesh()for accessing cortical surfaces by hemisphere and type -
get_cerebellar_flatmap()for the SUIT flatmap mesh -
available_cortical_surfaces()andavailable_cerebellar_surfaces()for discovery
