Hello community,

here is the log from the commit of package python-python-rtmidi for 
openSUSE:Factory checked in at 2020-07-20 21:09:22
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-python-rtmidi (Old)
 and      /work/SRC/openSUSE:Factory/.python-python-rtmidi.new.3592 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-python-rtmidi"

Mon Jul 20 21:09:22 2020 rev:2 rq:821968 version:1.4.2

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/python-python-rtmidi/python-python-rtmidi.changes    
    2020-06-23 21:06:59.738307677 +0200
+++ 
/work/SRC/openSUSE:Factory/.python-python-rtmidi.new.3592/python-python-rtmidi.changes
      2020-07-20 21:11:27.717706765 +0200
@@ -1,0 +2,13 @@
+Mon Jul 20 17:44:05 UTC 2020 - Mia Herkt <[email protected]>
+
+- Fix rpmlint warnings
+- Update to 1.4.2
+Enhancements:
+  * Added more helpful aliases for MIDI events/controllers
+    constants
+
+Examples:
+  * Added ccstore advanced example to show how to remember last
+    seen controller change values
+
+-------------------------------------------------------------------

Old:
----
  python-rtmidi-1.4.1.tar.gz

New:
----
  python-rtmidi-1.4.2.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-python-rtmidi.spec ++++++
--- /var/tmp/diff_new_pack.BZG4ms/_old  2020-07-20 21:11:29.173708240 +0200
+++ /var/tmp/diff_new_pack.BZG4ms/_new  2020-07-20 21:11:29.177708245 +0200
@@ -18,7 +18,7 @@
 
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
 Name:           python-python-rtmidi
-Version:        1.4.1
+Version:        1.4.2
 Release:        0
 Summary:        Python binding for the RtMidi C++ library
 License:        MIT
@@ -59,6 +59,7 @@
 
 %prep
 %setup -q -n python-rtmidi-%{version}
+sed -i 's,/usr/bin/env python,/usr/bin/%{python_for_executables},' 
examples/*.py examples/*/*.py
 
 %build
 %python_build
@@ -70,6 +71,7 @@
 sphinx-apidoc -o docs/ rtmidi rtmidi/release.py
 cat docs/api.rst.inc >> docs/rtmidi.rst
 %make_build -C docs html
+rm docs/_build/html/.buildinfo docs/_build/html/objects.inv
 
 %install
 %python_install

++++++ python-rtmidi-1.4.1.tar.gz -> python-rtmidi-1.4.2.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rtmidi-1.4.1/CHANGELOG.rst 
new/python-rtmidi-1.4.2/CHANGELOG.rst
--- old/python-rtmidi-1.4.1/CHANGELOG.rst       2020-04-16 14:44:43.000000000 
+0200
+++ new/python-rtmidi-1.4.2/CHANGELOG.rst       2020-07-18 17:13:29.000000000 
+0200
@@ -5,6 +5,17 @@
 <https://github.com/SpotlightKid/python-rtmidi/commits/master>`_.
 
 
+2020-07-18 version 1.4.2
+------------------------
+
+Enhancements:
+    * Added more helpful aliases for MIDI events/controllers constants.
+
+Examples:
+    * Added ``ccstore`` advanced example to show how to remember last seen
+      controller change values (#64).
+
+
 2020-04-16 version 1.4.1
 ------------------------
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rtmidi-1.4.1/INSTALL.rst 
new/python-rtmidi-1.4.2/INSTALL.rst
--- old/python-rtmidi-1.4.1/INSTALL.rst 2020-04-16 14:49:52.000000000 +0200
+++ new/python-rtmidi-1.4.2/INSTALL.rst 2020-07-18 17:18:20.000000000 +0200
@@ -101,8 +101,8 @@
 version, extract and install it, use the following commands::
 
     $ pip download python-rtmidi
-    $ tar -xzf python-rtmidi-1.4.1.tar.gz
-    $ cd python-rtmidi-1.4.1
+    $ tar -xzf python-rtmidi-1.4.2.tar.gz
+    $ cd python-rtmidi-1.4.2
     $ python setup.py install
 
 On Linux or macOS / OS X, if you want to install python-rtmidi into the
@@ -162,7 +162,7 @@
 If you want to change the Cython source file ``_rtmidi.pyx`` or want to
 recompile ``_rtmidi.cpp`` with a newer Cython version, you'll need to install
 Cython >= 0.28. The ``_rtmidi.cpp`` file in the current source distribution
-(version 1.4.1) is tagged with::
+(version 1.4.2) is tagged with::
 
     /* Generated by Cython 0.29.16 */
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rtmidi-1.4.1/PKG-INFO 
new/python-rtmidi-1.4.2/PKG-INFO
--- old/python-rtmidi-1.4.1/PKG-INFO    2020-04-16 14:49:52.213652600 +0200
+++ new/python-rtmidi-1.4.2/PKG-INFO    2020-07-18 17:18:20.530424000 +0200
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: python-rtmidi
-Version: 1.4.1
+Version: 1.4.2
 Summary: A Python binding for the RtMidi C++ library implemented using Cython.
 Home-page: https://chrisarndt.de/projects/python-rtmidi/
 Author: Christopher Arndt
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rtmidi-1.4.1/examples/advanced/ccstore.py 
new/python-rtmidi-1.4.2/examples/advanced/ccstore.py
--- old/python-rtmidi-1.4.1/examples/advanced/ccstore.py        1970-01-01 
01:00:00.000000000 +0100
+++ new/python-rtmidi-1.4.2/examples/advanced/ccstore.py        2020-07-18 
17:10:18.000000000 +0200
@@ -0,0 +1,66 @@
+#!/usr/bin/env python
+"""Record last seen value of specific Control Change events.
+
+The main loop prints out last seen value of specific Control Change events
+every second. The control change events are received by a MIDI input
+callback, which gets called on every MIDI event received and runs
+independently from the main loop.
+
+"""
+
+import time
+
+from rtmidi.midiutil import open_midiinput
+from rtmidi.midiconstants import (
+    CONTROL_CHANGE,
+    MODULATION,
+    CHANNEL_VOLUME,
+    EXPRESSION_CONTROLLER,
+)
+
+
+CONTROLLERS = (MODULATION, CHANNEL_VOLUME, EXPRESSION_CONTROLLER)
+
+
+class MidiInHandler:
+    def __init__(self, channel=1, controllers=None):
+        self.ch = channel
+        self.ccs = controllers or ()
+        self._cur_value = {}
+
+    def __call__(self, event, *args):
+        event, delta = event
+        status = event[0] & 0xF0
+        ch = event[0] & 0xF
+
+        if status == CONTROL_CHANGE and ch == self.ch - 1 and event[1] in 
self.ccs:
+            self._cur_value[event[1]] = event[2]
+
+    def get(self, cc, default=None):
+        return self._cur_value.get(cc, default)
+
+
+def main(args):
+    midiin, _ = open_midiinput(args[0] if args else None)
+
+    # record Modulation, Volume and Expression CC events
+    handler = MidiInHandler(channel=1, controllers=CONTROLLERS)
+    midiin.set_callback(handler)
+
+    try:
+        with midiin:
+            while True:
+                for cc in CONTROLLERS:
+                    print("CC #%i: %s" % (cc, handler.get(cc)))
+
+                print("--- ")
+                time.sleep(1)
+    except KeyboardInterrupt:
+        pass
+    finally:
+        del midiin
+
+
+if __name__ == '__main__':
+    import sys
+    main(sys.argv[1:])
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rtmidi-1.4.1/python_rtmidi.egg-info/PKG-INFO 
new/python-rtmidi-1.4.2/python_rtmidi.egg-info/PKG-INFO
--- old/python-rtmidi-1.4.1/python_rtmidi.egg-info/PKG-INFO     2020-04-16 
14:49:52.000000000 +0200
+++ new/python-rtmidi-1.4.2/python_rtmidi.egg-info/PKG-INFO     2020-07-18 
17:18:20.000000000 +0200
@@ -1,6 +1,6 @@
 Metadata-Version: 1.1
 Name: python-rtmidi
-Version: 1.4.1
+Version: 1.4.2
 Summary: A Python binding for the RtMidi C++ library implemented using Cython.
 Home-page: https://chrisarndt.de/projects/python-rtmidi/
 Author: Christopher Arndt
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/python-rtmidi-1.4.1/python_rtmidi.egg-info/SOURCES.txt 
new/python-rtmidi-1.4.2/python_rtmidi.egg-info/SOURCES.txt
--- old/python-rtmidi-1.4.1/python_rtmidi.egg-info/SOURCES.txt  2020-04-16 
14:49:52.000000000 +0200
+++ new/python-rtmidi-1.4.2/python_rtmidi.egg-info/SOURCES.txt  2020-07-18 
17:18:20.000000000 +0200
@@ -27,6 +27,7 @@
 docs/usage.rst
 examples/sendsysex.py
 examples/wavetablemodstep.py
+examples/advanced/ccstore.py
 examples/advanced/midiclock.py
 examples/advanced/midioutwrapper.py
 examples/advanced/recvrpn.py
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rtmidi-1.4.1/rtmidi/midiconstants.py 
new/python-rtmidi-1.4.2/rtmidi/midiconstants.py
--- old/python-rtmidi-1.4.1/rtmidi/midiconstants.py     2020-01-19 
17:49:07.000000000 +0100
+++ new/python-rtmidi-1.4.2/rtmidi/midiconstants.py     2020-05-11 
18:26:24.000000000 +0200
@@ -11,7 +11,7 @@
 NOTE_ON = 0x90
 # 1001cccc 0nnnnnnn 0vvvvvvv (channel, note, velocity)
 
-POLYPHONIC_PRESSURE = POLY_PRESSURE = 0xA0
+POLY_AFTERTOUCH = POLYPHONIC_PRESSURE = POLY_PRESSURE = 0xA0
 # 1010cccc 0nnnnnnn 0vvvvvvv (channel, note, velocity)
 
 # see Channel Mode Messages for Controller Numbers
@@ -21,7 +21,7 @@
 PROGRAM_CHANGE = 0xC0
 # 1100cccc 0ppppppp (channel, program)
 
-CHANNEL_PRESSURE = MONO_PRESSURE = 0xD0
+CHANNEL_AFTERTOUCH = CHANNEL_PRESSURE = MONO_PRESSURE = 0xD0
 # 1101cccc 0ppppppp (channel, pressure)
 
 PITCH_BEND = 0xE0
@@ -41,10 +41,10 @@
 FOOT_CONTROLLER = FOOT_CONTROLLER_MSB = 0x04
 PORTAMENTO_TIME = PORTAMENTO_TIME_MSB = 0x05
 DATA_ENTRY = DATA_ENTRY_MSB = 0x06
-CHANNEL_VOLUME = CHANNEL_VOLUME_MSB = 0x07
+VOLUME = CHANNEL_VOLUME = CHANNEL_VOLUME_MSB = 0x07
 BALANCE = BALANCE_MSB = 0x08
 PAN = PAN_MSB = 0x0A
-EXPRESSION_CONTROLLER = EXPRESSION_CONTROLLER_MSB = 0x0B
+EXPRESSION = EXPRESSION_CONTROLLER = EXPRESSION_CONTROLLER_MSB = 0x0B
 EFFECT_CONTROL_1 = EFFECT_CONTROL_1_MSB = 0x0C
 EFFECT_CONTROL_2 = EFFECT_CONTROL_2_MSB = 0x0D
 GENERAL_PURPOSE_CONTROLLER_1 = GENERAL_PURPOSE_CONTROLLER_1_MSB = 0x10
@@ -55,15 +55,15 @@
 # High resolution continuous controllers (LSB)
 
 BANK_SELECT_LSB = 0x20
-MODULATION_WHEEL_LSB = 0x21
+MODULATION_LSB = MODULATION_WHEEL_LSB = 0x21
 BREATH_CONTROLLER_LSB = 0x22
 FOOT_CONTROLLER_LSB = 0x24
 PORTAMENTO_TIME_LSB = 0x25
 DATA_ENTRY_LSB = 0x26
-CHANNEL_VOLUME_LSB = 0x27
+VOLUME_LSB = CHANNEL_VOLUME_LSB = 0x27
 BALANCE_LSB = 0x28
 PAN_LSB = 0x2A
-EXPRESSION_CONTROLLER_LSB = 0x2B
+EXPRESSION_LSB = EXPRESSION_CONTROLLER_LSB = 0x2B
 EFFECT_CONTROL_1_LSB = 0x2C
 EFFECT_CONTROL_2_LSB = 0x2D
 GENERAL_PURPOSE_CONTROLLER_1_LSB = 0x30
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/python-rtmidi-1.4.1/rtmidi/release.py 
new/python-rtmidi-1.4.2/rtmidi/release.py
--- old/python-rtmidi-1.4.1/rtmidi/release.py   2020-04-16 14:43:04.000000000 
+0200
+++ new/python-rtmidi-1.4.2/rtmidi/release.py   2020-07-18 17:14:02.000000000 
+0200
@@ -69,7 +69,7 @@
 """
 
 name = 'python-rtmidi'
-version = '1.4.1'
+version = '1.4.2'
 description = __doc__.splitlines()
 keywords = 'rtmidi, midi, music'
 author = 'Christopher Arndt'


Reply via email to