happycube / ld-decode

Software defined LaserDisc decoder
GNU General Public License v3.0
307 stars 80 forks source link

Fix unpack_data_4_40's return type #822

Closed atsampson closed 1 year ago

atsampson commented 1 year ago

It's intending to return an np.ndarray of int16s, but the final shift was converting to int64. The numpy documentation warns that the typing rules for left_shift "can lead to unexpected results".

Found while looking at #815 - I've confirmed that this now produces the same output as the .ldf reader by hashing the returned array.