Commit graph

14 commits

Author SHA1 Message Date
72f3e51b7b
Add libftw3, receive audio input and perform fft
This receives the audio input, performs the fft on it and has all the nescessary
preparations for then binding the audio data to the 2d texture for the GLSL.

Signed-off-by: Tyrolyean <tyrolyean@tyrolyean.net>
2022-07-19 00:23:43 +02:00
7e190a5729
Add data structures and functions
Signed-off-by: Tyrolyean <tyrolyean@tyrolyean.net>
2022-07-18 19:56:18 +02:00
84595eff00
Auto-set pipe size according to frame size, add iSampleRate uniform
The pipe size is now set automatically to avoid unnescessary buffering of frames
which aren't supposes to be there yet as well as preventing partial reads and
writes when larger resolutuions are used.

The iSampleRate uniform was added according to shadertoy spec.

Signed-off-by: Tyrolyean <tyrolyean@tyrolyean.net>
2022-07-18 00:59:36 +02:00
f0ffbc7c33
Set to newer c-standard and add source code fortification
The fortify source code was added to prevent builds from passing but then
failing in our build system and the c-standard was set to c11 to avoid the
compiler yelling at me whenever i want to print a size_t.

Signed-off-by: Tyrolyean <tyrolyean@tyrolyean.net>
2022-07-18 00:58:11 +02:00
47bbca6806
Add fix for output being O_NONBLOCK
This tries to remove the O_NONBLOCK flag from an output FD if the output seems
to be setup this way.

Signed-off-by: Tyrolyean <tyrolyean@tyrolyean.net>
2022-07-18 00:06:34 +02:00
51f808d12f
Revert "Add fix for O_NONBLOCK file-descriptor as output pipe"
This reverts commit be8f7d1716.

This was reverted as with this commit the program would consume large amounts
of cpu time just looping and calling the write function, which would not block.
2022-07-17 23:53:44 +02:00
75cdd01de8
Add sampling rate for audio input and data structures
Signed-off-by: Tyrolyean <tyrolyean@tyrolyean.net>
2022-07-17 23:52:56 +02:00
be8f7d1716
Add fix for O_NONBLOCK file-descriptor as output pipe
If the output of an fd is a pipe with O_NONBLOCK set, the script will die as
soon as the pipe fills up due to the write call returning with EAGAIN. This
fixes that.

Signed-off-by: Tyrolyean <tyrolyean@tyrolyean.net>
2022-07-17 20:03:32 +02:00
4123b78a81 Back to the future
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2022-07-17 15:59:24 +02:00
13e1363e0b Add license boilerplate
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2022-07-17 15:58:53 +02:00
f21ecc71c7 Make the window invisible if dumping to stdout
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2022-07-17 03:25:37 +02:00
319b283868 Cleanup window handling a little bit
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2022-07-17 02:29:26 +02:00
75baf054e5 Implement "dump raw frame buffer to stdout"
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2022-07-17 01:58:46 +02:00
acaef93bd8 Initial commit
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2022-07-16 22:13:49 +02:00