summaryrefslogtreecommitdiffstats
path: root/src/sample.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/sample.h')
-rw-r--r--src/sample.h12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/sample.h b/src/sample.h
index 697937e0..1fd764d7 100644
--- a/src/sample.h
+++ b/src/sample.h
@@ -14,7 +14,11 @@ enum pa_sample_format {
PA_SAMPLE_MAX
};
+#ifdef WORDS_BIGENDIAN
+#define PA_SAMPLE_S16NE PA_SAMPLE_S16BE
+#else
#define PA_SAMPLE_S16NE PA_SAMPLE_S16LE
+#endif
struct pa_sample_spec {
enum pa_sample_format format;
@@ -22,10 +26,10 @@ struct pa_sample_spec {
uint8_t channels;
};
-size_t pa_bytes_per_second(struct pa_sample_spec *spec);
-size_t pa_sample_size(struct pa_sample_spec *spec);
-uint32_t pa_samples_usec(size_t length, struct pa_sample_spec *spec);
+size_t pa_bytes_per_second(const struct pa_sample_spec *spec);
+size_t pa_sample_size(const struct pa_sample_spec *spec);
+uint32_t pa_samples_usec(size_t length, const struct pa_sample_spec *spec);
-int pa_sample_spec_valid(struct pa_sample_spec *spec);
+int pa_sample_spec_valid(const struct pa_sample_spec *spec);
#endif