]> code.delx.au - pulseaudio/blobdiff - src/pulse/sample.h
core: Fix uninit pointer read in protocol-native
[pulseaudio] / src / pulse / sample.h
index 34087e04583ae218e80d05df616e1fc45e9315d4..86973d41faafcf6e424d000b05c9a7d6af3d4aae 100644 (file)
@@ -289,6 +289,16 @@ size_t pa_usec_to_bytes(pa_usec_t t, const pa_sample_spec *spec) PA_GCC_PURE;
  * pa_sample_spec_valid() will fail for it. \since 0.9.13 */
 pa_sample_spec* pa_sample_spec_init(pa_sample_spec *spec);
 
+/** Return non-zero if the given integer is a valid sample format. \since 5.0 */
+int pa_sample_format_valid(unsigned format) PA_GCC_PURE;
+
+/** Return non-zero if the rate is within the supported range. \since 5.0 */
+int pa_sample_rate_valid(uint32_t rate) PA_GCC_PURE;
+
+/** Return non-zero if the channel count is within the supported range.
+ * \since 5.0 */
+int pa_channels_valid(uint8_t channels) PA_GCC_PURE;
+
 /** Return non-zero when the sample type specification is valid */
 int pa_sample_spec_valid(const pa_sample_spec *spec) PA_GCC_PURE;