public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t] tests/kms_chamelium: document capture audio buffer size constraints
@ 2019-05-17 10:27 Simon Ser
  2019-05-17 11:20 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Simon Ser @ 2019-05-17 10:27 UTC (permalink / raw)
  To: igt-dev; +Cc: martin.peres

Explain why we need to choose a big enough buffer for audio capture.

Signed-off-by: Simon Ser <simon.ser@intel.com>
---
 tests/kms_chamelium.c | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/tests/kms_chamelium.c b/tests/kms_chamelium.c
index c8b6b22d7b4a..4db604d32cae 100644
--- a/tests/kms_chamelium.c
+++ b/tests/kms_chamelium.c
@@ -924,7 +924,14 @@ do_test_display_audio(data_t *data, struct chamelium_port *port,

 	/* Needs to be a multiple of 128, because that's the number of samples
 	 * we get per channel each time we receive an audio page from the
-	 * Chamelium device. */
+	 * Chamelium device.
+	 *
+	 * Additionally, this value needs to be high enough to guarantee we
+	 * capture a full period of each sine we generate. If we capture 2048
+	 * samples at a 192KHz sampling rate, we get a full period for a >94Hz
+	 * sines. For lower sampling rates, the capture duration will be
+	 * longer.
+	 */
 	channel_len = CAPTURE_SAMPLES;
 	channel = malloc(sizeof(double) * channel_len);

--
2.21.0

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-05-17 14:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-05-17 10:27 [igt-dev] [PATCH i-g-t] tests/kms_chamelium: document capture audio buffer size constraints Simon Ser
2019-05-17 11:20 ` [igt-dev] ✓ Fi.CI.BAT: success for " Patchwork
2019-05-17 11:52 ` [igt-dev] [PATCH i-g-t] " Martin Peres
2019-05-17 14:43 ` [igt-dev] ✓ Fi.CI.IGT: success for " Patchwork

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox