diff options
author | dec05eba <dec05eba@protonmail.com> | 2022-10-16 02:08:40 +0200 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2022-10-16 04:15:09 +0200 |
commit | a7e0dbd83381377bd05a3fa988511d3713996370 (patch) | |
tree | 0e18f4c7b95aa4cf79d6646bca77ed5f03c65fb3 /src/sound.cpp | |
parent | 93d46b976730bced7a70be1617a0171600167314 (diff) |
Refactor xcomposite into abstract capture api
Refactor c++ files into c files, more usable
Diffstat (limited to 'src/sound.cpp')
-rw-r--r-- | src/sound.cpp | 28 |
1 files changed, 3 insertions, 25 deletions
diff --git a/src/sound.cpp b/src/sound.cpp index 794d3ea..9083f1e 100644 --- a/src/sound.cpp +++ b/src/sound.cpp @@ -1,21 +1,7 @@ -/* - Copyright (C) 2020 dec05eba - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see <https://www.gnu.org/licenses/>. -*/ - #include "../include/sound.hpp" +extern "C" { +#include "../include/time.h" +} #include <stdlib.h> #include <stdio.h> @@ -43,14 +29,6 @@ } \ } while(false); -static double clock_get_monotonic_seconds() { - struct timespec ts; - ts.tv_sec = 0; - ts.tv_nsec = 0; - clock_gettime(CLOCK_MONOTONIC, &ts); - return (double)ts.tv_sec + (double)ts.tv_nsec * 0.000000001; -} - struct pa_handle { pa_context *context; pa_stream *stream; |