simple-carla 2.5.1__tar.gz → 2.6.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {simple_carla-2.5.1 → simple_carla-2.6.0}/PKG-INFO +1 -1
- {simple_carla-2.5.1 → simple_carla-2.6.0}/pyproject.toml +1 -1
- {simple_carla-2.5.1 → simple_carla-2.6.0}/simple_carla/__init__.py +29 -33
- {simple_carla-2.5.1 → simple_carla-2.6.0}/simple_carla/qt.py +3 -3
- {simple_carla-2.5.1 → simple_carla-2.6.0}/simple_carla/scripts/sc_plugin_def.py +4 -4
- {simple_carla-2.5.1 → simple_carla-2.6.0}/simple_carla/scripts/sc_plugin_info.py +3 -2
- {simple_carla-2.5.1 → simple_carla-2.6.0}/tests/carla.py +1 -1
- {simple_carla-2.5.1 → simple_carla-2.6.0}/.gitignore +0 -0
- {simple_carla-2.5.1 → simple_carla-2.6.0}/LICENSE +0 -0
- {simple_carla-2.5.1 → simple_carla-2.6.0}/README.md +0 -0
- {simple_carla-2.5.1 → simple_carla-2.6.0}/simple_carla/plugin_dialog.py +0 -0
- {simple_carla-2.5.1 → simple_carla-2.6.0}/simple_carla/scripts/__init__.py +0 -0
- {simple_carla-2.5.1 → simple_carla-2.6.0}/tests/qt_carla.py +0 -0
@@ -19,7 +19,7 @@ sc-plugin-def = "simple_carla.scripts.sc_plugin_def:main"
|
|
19
19
|
sc-plugin-info = "simple_carla.scripts.sc_plugin_info:main"
|
20
20
|
|
21
21
|
[bumpver]
|
22
|
-
current_version = "2.
|
22
|
+
current_version = "2.6.0"
|
23
23
|
version_pattern = "MAJOR.MINOR.PATCH"
|
24
24
|
commit_message = "Bump version {old_version} -> {new_version}"
|
25
25
|
commit = true
|
@@ -240,7 +240,7 @@ from carla_backend import (
|
|
240
240
|
)
|
241
241
|
|
242
242
|
|
243
|
-
__version__ = "2.
|
243
|
+
__version__ = "2.6.0"
|
244
244
|
|
245
245
|
|
246
246
|
# -------------------------------------------------------------------
|
@@ -373,7 +373,7 @@ class _SimpleCarla(CarlaHostDLL):
|
|
373
373
|
Make sure to call carla_engine_idle() at regular intervals afterwards.
|
374
374
|
driver_name: Driver to use
|
375
375
|
"""
|
376
|
-
self.__engine_idle_thread = threading.Thread(target=self.__engine_idle)
|
376
|
+
self.__engine_idle_thread = threading.Thread(target = self.__engine_idle)
|
377
377
|
if super().engine_init(driver_name, self.client_name):
|
378
378
|
self._run_idle_loop = True
|
379
379
|
self.__engine_idle_thread.start()
|
@@ -1514,7 +1514,6 @@ class _SimpleCarla(CarlaHostDLL):
|
|
1514
1514
|
# ================================================================================
|
1515
1515
|
|
1516
1516
|
def add_plugin(self, plugin):
|
1517
|
-
logging.debug('add_plugin %s', plugin.unique_name)
|
1518
1517
|
self._plugin_by_uuid[plugin.unique_name] = plugin
|
1519
1518
|
if not self._add_plugin( # Carla parameter
|
1520
1519
|
# ----------------------------------------- # ---------------
|
@@ -2714,8 +2713,9 @@ class Plugin(PatchbayClient):
|
|
2714
2713
|
|
2715
2714
|
_save_state_keys = [ 'moniker',
|
2716
2715
|
'active', 'volume', 'dry_wet', 'panning', 'balance_left', 'balance_right',
|
2717
|
-
'prefer_generic_dialog', 'send_all_sound_off', 'send_channel_pressure',
|
2718
|
-
'
|
2716
|
+
'prefer_generic_dialog', 'send_all_sound_off', 'send_channel_pressure',
|
2717
|
+
'send_control_changes', 'send_note_aftertouch', 'send_pitchbend',
|
2718
|
+
'send_program_changes', 'skip_sending_notes', 'force_stereo' ]
|
2719
2719
|
|
2720
2720
|
def on_ready(self, callback):
|
2721
2721
|
self._cb_ready = callback
|
@@ -2726,7 +2726,7 @@ class Plugin(PatchbayClient):
|
|
2726
2726
|
# -------------------------------------------------------------------
|
2727
2727
|
# Internal lifecycle events
|
2728
2728
|
|
2729
|
-
def __init__(self, plugin_def = None, saved_state = None):
|
2729
|
+
def __init__(self, plugin_def = None, *, saved_state = None):
|
2730
2730
|
if plugin_def is None:
|
2731
2731
|
if self.plugin_def is None:
|
2732
2732
|
raise RuntimeError("No definition for plugin")
|
@@ -2757,7 +2757,7 @@ class Plugin(PatchbayClient):
|
|
2757
2757
|
self._unmute_volume = 1.0
|
2758
2758
|
self._unbypass_wet = 1.0
|
2759
2759
|
self.parameters = {} # Parameter objects. Key is parameter_id.
|
2760
|
-
self._midi_notes = np_zeros((16, 128), dtype=bool) # array for determining whether midi active.
|
2760
|
+
self._midi_notes = np_zeros((16, 128), dtype = bool) # array for determining whether midi active.
|
2761
2761
|
|
2762
2762
|
self.unique_name = Carla.instance.get_unique_name(self)
|
2763
2763
|
self.moniker = self.unique_name if saved_state is None else saved_state["vars"]["moniker"]
|
@@ -2931,7 +2931,8 @@ class Plugin(PatchbayClient):
|
|
2931
2931
|
This function is called from "check_ports_ready" before calling Plugin.ready()
|
2932
2932
|
"""
|
2933
2933
|
for key, value in self.saved_state["vars"].items():
|
2934
|
-
|
2934
|
+
if not value is None:
|
2935
|
+
setattr(self, key, value)
|
2935
2936
|
for key, value in self.saved_state["parameters"].items():
|
2936
2937
|
if not value is None and int(key) in self.parameters:
|
2937
2938
|
self.parameters[int(key)].value = value
|
@@ -3247,11 +3248,10 @@ class Plugin(PatchbayClient):
|
|
3247
3248
|
self.set_dry_wet(value)
|
3248
3249
|
|
3249
3250
|
def set_dry_wet(self, value):
|
3250
|
-
if isinstance(value, float):
|
3251
|
-
|
3252
|
-
|
3253
|
-
|
3254
|
-
Carla.instance.set_drywet(self.plugin_id, value)
|
3251
|
+
if not isinstance(value, float) or value < 0.0 or value > 1.0:
|
3252
|
+
raise ValueError()
|
3253
|
+
self._dry_wet = value
|
3254
|
+
Carla.instance.set_drywet(self.plugin_id, value)
|
3255
3255
|
|
3256
3256
|
@property
|
3257
3257
|
def volume(self):
|
@@ -3270,11 +3270,10 @@ class Plugin(PatchbayClient):
|
|
3270
3270
|
self.set_volume(value)
|
3271
3271
|
|
3272
3272
|
def set_volume(self, value):
|
3273
|
-
if isinstance(value, float):
|
3274
|
-
|
3275
|
-
|
3276
|
-
|
3277
|
-
Carla.instance.set_volume(self.plugin_id, value)
|
3273
|
+
if not isinstance(value, float) or value < 0.0 or value > 1.0:
|
3274
|
+
raise ValueError()
|
3275
|
+
self._volume = value
|
3276
|
+
Carla.instance.set_volume(self.plugin_id, value)
|
3278
3277
|
|
3279
3278
|
@property
|
3280
3279
|
def balance_left(self):
|
@@ -3293,11 +3292,10 @@ class Plugin(PatchbayClient):
|
|
3293
3292
|
self.set_balance_left(value)
|
3294
3293
|
|
3295
3294
|
def set_balance_left(self, value):
|
3296
|
-
if isinstance(value, float):
|
3297
|
-
|
3298
|
-
|
3299
|
-
|
3300
|
-
Carla.instance.set_balance_left(self.plugin_id, value)
|
3295
|
+
if not isinstance(value, float) or value < -1.0 or value > 1.0:
|
3296
|
+
raise ValueError()
|
3297
|
+
self._balance_left = value
|
3298
|
+
Carla.instance.set_balance_left(self.plugin_id, value)
|
3301
3299
|
|
3302
3300
|
@property
|
3303
3301
|
def balance_right(self):
|
@@ -3316,11 +3314,10 @@ class Plugin(PatchbayClient):
|
|
3316
3314
|
self.set_balance_right(value)
|
3317
3315
|
|
3318
3316
|
def set_balance_right(self, value):
|
3319
|
-
if isinstance(value, float):
|
3320
|
-
|
3321
|
-
|
3322
|
-
|
3323
|
-
Carla.instance.set_balance_right(self.plugin_id, value)
|
3317
|
+
if not isinstance(value, float) or value < -1.0 or value > 1.0:
|
3318
|
+
raise ValueError()
|
3319
|
+
self._balance_right = value
|
3320
|
+
Carla.instance.set_balance_right(self.plugin_id, value)
|
3324
3321
|
|
3325
3322
|
@property
|
3326
3323
|
def balance_center(self):
|
@@ -3349,11 +3346,10 @@ class Plugin(PatchbayClient):
|
|
3349
3346
|
self.set_panning(value)
|
3350
3347
|
|
3351
3348
|
def set_panning(self, value):
|
3352
|
-
if isinstance(value, float):
|
3353
|
-
|
3354
|
-
|
3355
|
-
|
3356
|
-
Carla.instance.set_panning(self.plugin_id, value)
|
3349
|
+
if not isinstance(value, float) or value < -1.0 or value > 1.0:
|
3350
|
+
raise ValueError()
|
3351
|
+
self._panning = value
|
3352
|
+
Carla.instance.set_panning(self.plugin_id, value)
|
3357
3353
|
|
3358
3354
|
@property
|
3359
3355
|
def ctrl_channel(self):
|
@@ -341,7 +341,7 @@ class AbstractQtPlugin(Plugin):
|
|
341
341
|
|
342
342
|
plugin_def = {...}
|
343
343
|
|
344
|
-
def __init__(self, parent, plugin_def, saved_state = None):
|
344
|
+
def __init__(self, parent, plugin_def, *, saved_state = None):
|
345
345
|
QFrame.__init__(self, parent)
|
346
346
|
AbstractQtPlugin.__init__(self, plugin_def, saved_state)
|
347
347
|
|
@@ -437,9 +437,9 @@ class QtPlugin(AbstractQtPlugin, QObject):
|
|
437
437
|
sig_ctrl_channel_changed = pyqtSignal(Plugin, float)
|
438
438
|
|
439
439
|
|
440
|
-
def __init__(self, plugin_def=None, saved_state=None):
|
440
|
+
def __init__(self, plugin_def = None, *, saved_state = None):
|
441
441
|
QObject.__init__(self)
|
442
|
-
Plugin.__init__(self, plugin_def, saved_state)
|
442
|
+
Plugin.__init__(self, plugin_def, saved_state = saved_state)
|
443
443
|
|
444
444
|
|
445
445
|
# end simple_carla/qt.py
|
@@ -48,10 +48,10 @@ class MainWindow(QMainWindow):
|
|
48
48
|
def main():
|
49
49
|
p = argparse.ArgumentParser()
|
50
50
|
p.epilog = __doc__
|
51
|
-
p.add_argument("--full", "-f", action="store_true",
|
52
|
-
help="Spit out the full plugin definition.")
|
53
|
-
p.add_argument("--verbose", "-v", action="store_true",
|
54
|
-
help="Show detailed debug information")
|
51
|
+
p.add_argument("--full", "-f", action = "store_true",
|
52
|
+
help = "Spit out the full plugin definition.")
|
53
|
+
p.add_argument("--verbose", "-v", action = "store_true",
|
54
|
+
help = "Show detailed debug information")
|
55
55
|
options = p.parse_args()
|
56
56
|
logging.basicConfig(
|
57
57
|
level = logging.DEBUG if options.verbose else logging.ERROR,
|
@@ -100,6 +100,7 @@ Filename: {plugin.filename}
|
|
100
100
|
print(label, getattr(param, att));
|
101
101
|
except AttributeError:
|
102
102
|
pass
|
103
|
+
print()
|
103
104
|
self.carla.delete()
|
104
105
|
QApplication.instance().quit()
|
105
106
|
|
@@ -107,8 +108,8 @@ Filename: {plugin.filename}
|
|
107
108
|
def main():
|
108
109
|
p = argparse.ArgumentParser()
|
109
110
|
p.epilog = __doc__
|
110
|
-
p.add_argument("--verbose", "-v", action="store_true",
|
111
|
-
help="Show detailed debug information")
|
111
|
+
p.add_argument("--verbose", "-v", action = "store_true",
|
112
|
+
help = "Show detailed debug information")
|
112
113
|
options = p.parse_args()
|
113
114
|
logging.basicConfig(
|
114
115
|
level = logging.DEBUG if options.verbose else logging.ERROR,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|