chrippa / python-librtmp

python-librtmp is a RTMP client library. It uses the implementation provided by librtmp via cffi.
BSD 2-Clause "Simplified" License
154 stars 33 forks source link

not plaintext #13

Closed ghost closed 10 years ago

ghost commented 10 years ago

Before switching to python-librtmp i used rtmp-python (https://github.com/prekageo/rtmp-python). There i could do something like client.reader.next() to get packets in dicts, without no unexpected "weird" signs (as demonstrated below).

I get these signs (or whatever it's called) in every packet, imgur-2014_10_31-00 43 56

and i'm not sure why.

Is this expected? If so, is there an easy way to get rid of the weird signs or another solution?

ghost commented 10 years ago

I've come up with a temporarily solution for my case, wrote a simple, terrible parser to remove the stuff that causes the weird box signs in the print. :P

chrippa commented 10 years ago

python-librtmp can handle method calls between you and the server in a nice pythonic way, as described here. This is the preferred way to use the API.

If you wish to handle the packets yourself you can decode the data with librtmp.amf.decode_amf.

ghost commented 10 years ago

Alright, i went with librtmp.amf.decode_amf as it suits my needs better.

Thanks for the quick reply.