imageguy wrote:
I am looking for the most efficient method of replacing a repeating
sequence in a byte string returned from a imaging .dll, connected via

I receive the byte string with the following sequence 'bgrbgrbgrbgr'
and I would like to convert this to 'rbgrbgrbgrbg'

For speed, I would look at PIL or pygame for existing function, or use numpy -- read into 2-d array, swap first and third members, flatten.

--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to