pappersverk / rpi_fb_capture

Capture the Raspberry Pi's framebuffer
Apache License 2.0
11 stars 2 forks source link

Dithering plus tests #6

Closed fhunleth closed 4 years ago

fhunleth commented 4 years ago

This is a continuation of the work from #4. See https://github.com/pappersverk/rpi_fb_capture/pull/4#issuecomment-549153422.

luisgabrielroldan commented 4 years ago

The vertical stripes are fixed. As I always use the column scan format for the displays it was not properly tested :man_facepalming:.

The test are pretty good now. Good job! :tada:

fhunleth commented 4 years ago

Oh, good. I'm glad that works now. That also makes it sound like we need test coverage for column scan + dithering. Could you add that?

While you're at it, run mix format since the C formatting looks off. The Elixir looks good.

I don't think that I have time to put into this, so I'm not going to hold up merging this PR because of it. The code just feels really slow. I assume the displays you're using are too small to notice or the I2C/SPI buses are big bottlenecks too. If you do think that the performance is slow, please let me know so we can put time into addressing it. If the code has good enough performance, then we can fix later if ever needed.

luisgabrielroldan commented 4 years ago

Sure :+1: I will add the tests and fix the format.

The code just feels really slow.

I'm not sure how slow is the capture right now. Have you measured it?

I assume the displays you're using are too small to notice or the I2C/SPI buses are big bottlenecks too. If you do think that the performance is slow, please let me know so we can put time into addressing it. If the code has good enough performance, then we can fix later if ever needed.

Yeah, using SPI/I2C the capture speed is the least to worry about. That's because I'm thinking in to implement partial updates to tackle that in the OLED lib.