Browse Source

fix various compilation warnings

audio_region_bpm_change_fix
Alexandros Theodotou 5 months ago
parent
commit
4408fc6f62
Signed by: alex
GPG Key ID: 022EAE42313D70F3
  1. 2
      doc/user/plugins-files/plugins/plugin-browser.rst
  2. 20
      inc/audio/clip.h
  3. 4
      src/audio/clip.c
  4. 3
      src/audio/graph_thread.c
  5. 31
      src/audio/position.c
  6. 24
      src/audio/recording_manager.c
  7. 26
      src/audio/supported_file.c
  8. 27
      src/audio/windows_mmcss.c
  9. 3
      src/gui/backend/arranger_object.c
  10. 2
      src/utils/ui.c

2
doc/user/plugins-files/plugins/plugin-browser.rst

@ -30,7 +30,7 @@ Author @@ -30,7 +30,7 @@ Author
Filter by plugin manufacturer/author.
.. hint:: Built-in plugins can be found under
`Zrythm DAW` here.
`Zrythm DAW` here.
Category
Filter by category (`Delay`, `Distortion`, etc.).

20
inc/audio/clip.h

@ -1,21 +1,5 @@ @@ -1,21 +1,5 @@
/*
* Copyright (C) 2019-2021 Alexandros Theodotou <alex at zrythm dot org>
*
* This file is part of Zrythm
*
* Zrythm is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Zrythm 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 Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with Zrythm. If not, see <https://www.gnu.org/licenses/>.
*/
// SPDX-FileCopyrightText: © 2019-2021 Alexandros Theodotou <alex@zrythm.org>
// SPDX-License-Identifier: LicenseRef-ZrythmLicense
/**
* \file

4
src/audio/clip.c

@ -1,7 +1,5 @@ @@ -1,7 +1,5 @@
// SPDX-FileCopyrightText: © 2019-2022 Alexandros Theodotou <alex@zrythm.org>
// SPDX-License-Identifier: LicenseRef-ZrythmLicense
/*
* Copyright (C) 2019-2022 Alexandros Theodotou <alex at zrythm dot org>
*/
#include <stdlib.h>

3
src/audio/graph_thread.c

@ -436,9 +436,12 @@ graph_thread_new ( @@ -436,9 +436,12 @@ graph_thread_new (
return NULL;
}
#if defined (HAVE_JACK) || defined (__linux__)
bool realtime = true;
int priority = -22; /* RT priority (from ardour) */
#endif
#ifdef HAVE_JACK
if (AUDIO_ENGINE->audio_backend == AUDIO_BACKEND_JACK)
{

31
src/audio/position.c

@ -1,21 +1,5 @@ @@ -1,21 +1,5 @@
/*
* Copyright (C) 2018-2022 Alexandros Theodotou <alex at zrythm dot org>
*
* This file is part of Zrythm
*
* Zrythm is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Zrythm 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 Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with Zrythm. If not, see <https://www.gnu.org/licenses/>.
*/
// SPDX-FileCopyrightText: © 2018-2022 Alexandros Theodotou <alex@zrythm.org>
// SPDX-License-Identifier: LicenseRef-ZrythmLicense
#include <math.h>
@ -796,8 +780,9 @@ position_print (const Position * pos) @@ -796,8 +780,9 @@ position_print (const Position * pos)
char buf[140];
position_to_string (pos, buf);
g_message (
"%s (%ld frames | %f ticks)", buf, pos->frames,
pos->ticks);
"%s (%" SIGNED_FRAME_FORMAT " frames | "
"%f ticks)",
buf, pos->frames, pos->ticks);
}
void
@ -810,8 +795,10 @@ position_print_range ( @@ -810,8 +795,10 @@ position_print_range (
char buf2[140];
position_to_string (pos2, buf2);
g_message (
"%s (%ld) - %s (%ld) "
"<delta %ld frames %f ticks>",
"%s (%" SIGNED_FRAME_FORMAT ") - "
"%s (%" SIGNED_FRAME_FORMAT ") "
"<delta %" SIGNED_FRAME_FORMAT " frames "
"%f ticks>",
buf, pos->frames, buf2, pos2->frames,
pos2->frames - pos->frames,
pos2->ticks - pos->ticks);

24
src/audio/recording_manager.c

@ -1,21 +1,5 @@ @@ -1,21 +1,5 @@
/*
* Copyright (C) 2019-2022 Alexandros Theodotou <alex at zrythm dot org>
*
* This file is part of Zrythm
*
* Zrythm is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Zrythm 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 Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with Zrythm. If not, see <https://www.gnu.org/licenses/>.
*/
// SPDX-FileCopyrightText: © 2019-2022 Alexandros Theodotou <alex@zrythm.org>
// SPDX-License-Identifier: LicenseRef-ZrythmLicense
#include "actions/arranger_selections.h"
#include "audio/audio_region.h"
@ -1437,7 +1421,9 @@ handle_start_recording ( @@ -1437,7 +1421,9 @@ handle_start_recording (
start_frames + ev->nframes;
g_message (
"start %lu, end %lu", start_frames, end_frames);
"start %" UNSIGNED_FRAME_FORMAT ", "
"end %" UNSIGNED_FRAME_FORMAT,
start_frames, end_frames);
/* this is not needed because the cycle is
* already split */

26
src/audio/supported_file.c

@ -1,22 +1,7 @@ @@ -1,22 +1,7 @@
/*
* Copyright (C) 2019-2021 Alexandros Theodotou <alex at zrythm dot org>
*
* This file is part of Zrythm
*
* Zrythm is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Zrythm 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 Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with Zrythm. If not, see <https://www.gnu.org/licenses/>.
*/
// SPDX-FileCopyrightText: © 2019-2021 Alexandros Theodotou <alex@zrythm.org>
// SPDX-License-Identifier: LicenseRef-ZrythmLicense
#include <inttypes.h>
#include <stdlib.h>
#include "audio/encoder.h"
@ -296,8 +281,9 @@ supported_file_get_info_text_for_label ( @@ -296,8 +281,9 @@ supported_file_get_info_text_for_label (
_ (
"<b>%s</b>\n"
"Sample rate: %d\n"
"Length: %ld s %ld ms | BPM: %.1f\n"
"Channel(s): %d | Bitrate: %'d.%d kb/s\n"
"Length: %" PRId64 "s "
"%" PRId64 " ms | BPM: %.1f\n"
"Channel(s): %u | Bitrate: %'d.%d kb/s\n"
"Bit depth: %d bits"),
self->label, enc->nfo.sample_rate,
enc->nfo.length / 1000,

27
src/audio/windows_mmcss.c

@ -1,24 +1,11 @@ @@ -1,24 +1,11 @@
// SPDX-FileCopyrightText: © 2020 Alexandros Theodotou <alex@zrythm.org>
// SPDX-License-Identifier: LicenseRef-ZrythmLicense
/*
* Copyright (C) 2020 Alexandros Theodotou <alex at zrythm dot org>
*
* This file is part of Zrythm
*
* Zrythm is free software: you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Zrythm 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 Affero General Public License for more details.
*
* You should have received a copy of the GNU Affero General Public License
* along with Zrythm. If not, see <https://www.gnu.org/licenses/>.
*
* This file incorporates work covered by the following copyright and
* permission notice:
*
* ---
*
* Copyright (C) 2015 Tim Mayberry <mojofunk@gmail.com>
*
* This program is free software: you can redistribute it and/or modify
@ -33,6 +20,10 @@ @@ -33,6 +20,10 @@
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
* SPDX-License-Identifier: GPL-2.0-or-later
*
* ---
*/
#include "zrythm-config.h"
@ -158,7 +149,7 @@ windows_mmcss_set_thread_characteristics ( @@ -158,7 +149,7 @@ windows_mmcss_set_thread_characteristics (
DWORD task_index_dummy = 0;
*task_handle = AvSetMmThreadCharacteristicsA (
task_name, &task_index_dummy);
(char *) task_name, &task_index_dummy);
if (*task_handle == 0)

3
src/gui/backend/arranger_object.c

@ -827,7 +827,8 @@ arranger_object_print (const ArrangerObject * self) @@ -827,7 +827,8 @@ arranger_object_print (const ArrangerObject * self)
position_to_string (&pos, pos_str);
extra_info = g_strdup_printf (
" | audio clip total ticks %s "
"(%ld frames)",
"(%" UNSIGNED_FRAME_FORMAT
" frames)",
pos_str, clip->num_frames);
g_free (tmp);
}

2
src/utils/ui.c

@ -1018,7 +1018,7 @@ ui_get_locale_not_available_string ( @@ -1018,7 +1018,7 @@ ui_get_locale_not_available_string (
{
/* show warning */
#ifdef _WOE32
char template = _ (
char * template = _ (
"A locale for the language you have \
selected (%s) is not available. Please install one first \
and restart %s");

Loading…
Cancel
Save