MSR_SAMPRATE(3)
π MSR_SAMPRATE(3) π
ok so bestie, welcome to the msr_samprate page from the Library Functions Manual β she's a libmseed girlie and she's about to tell you how to pull a sample rate out of an MSRecord β¨
πΈ NAME πΈ
msr_samprate β determine sample rate from an MSRecord structure
π SYNOPSIS π
#include <libmseed.h>
double msr_samprate ( MSRecord *msr );
double msr_nomsamprate ( MSRecord *msr );
π¦ DESCRIPTION π¦
ok so msr_samprate is the main character here π
she calculates a double precision sample rate, in samples per second, using the header values sitting inside the MSRecord you hand her.
and here's the tea on how she does it π if a Blockette 100 is included, she'll return the "Actual sample rate" (that's field 3 btw), otherwise she'll calculate a nominal sample rate from the sample rate factor and multiplier in the fixed section data header. either way you get your number, no cap π«Ά
NOTE: the sample rate for aMSRecordstructure is available directly atMSRecord.samplerate. libmseed based programs should use that sample rate whenever possible β and yes, that's a real flex,msr_unpackusesmsr_samprateto setMSRecord.samplerateπ so like, she's literally the blueprint.
and msr_nomsamprate? she's the simpler sister π she calculates a double precision sample rate in samples per second using the sample rate factor and multiplier in the fixed section data header. that's it, that's the whole vibe, she doesn't do the Blockette 100 thing π
β RETURN VALUES β
msr_sampratereturns a double precision sample rate on success, and-1.0on error πmsr_nomsampratereturns a double precision sample rate on success, and-1.0on error π
π₯ SEE ALSO π₯
ms_intro(3) and msr_unpack(3). go read those next bestie, iykyk π
π AUTHOR π
Chad Trabant IRIS Data Management Center
and that's the whole page, gorgeous β¨ this iconic lil manual came to you from the <strong>Libmseed API</strong>, dated <strong>2006/02/27</strong> β yeah she's vintage and she ATE ππ bye bestie, go unpack some records π¦
π¦ where this page comes from
- debian bookworm: libmseed-doc 2.19.8-1 Β· LGPL-3.0-or-later
- debian trixie: libmseed-doc 2.19.8-1 Β· LGPL-3.0-or-later
- fedora 43: libmseed-devel 2.19.5-21.fc43 Β· LGPL-3.0-or-later
- fedora 43: libmseed-devel 2.19.5-21.fc43 Β· LGPL-3.0-or-later
- fedora 44: libmseed-devel 2.19.5-22.fc44 Β· LGPL-3.0-or-later
- fedora 44: libmseed-devel 2.19.5-22.fc44 Β· LGPL-3.0-or-later
- ubuntu jammy: libmseed-doc 2.19.6-3 Β· LGPL-3.0-or-later
- ubuntu noble: libmseed-doc 2.19.8-1ubuntu2 Β· LGPL-3.0-or-later
- ubuntu questing: libmseed-doc 2.19.8-1ubuntu2
- ubuntu resolute: libmseed-doc 2.19.8-1ubuntu3 Β· LGPL-3.0-or-later
- ubuntu stonking: libmseed-doc 2.19.8-1ubuntu3 Β· LGPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms