Comments (8)
I discovered that using the ESP32SPI_DMA bus for the display and editing the MAX_TRANSFER_SZ in Arduino_ESP32SPI_DMA.h to (32*1024) from (480 * 2 * 9) had a big impact to gif playback speed. I'm fairly satisfied with the quality now.
I placed the SD card on a separate SPI bus using the HSPI pins (using pin 36 for MISO instead of Pin 12). The bottle neck seems to be on the display side
However now I'm noticing that high quality jpgs from the SD card are slow too haha. My test image is ~240*240 and 67K in size and you can see the image be filled in row by row. I'll be trying to optimize this next
from arduino_gfx.
from arduino_gfx.
Using the GC9A01 and and SD breakout board.
I noticed that for Gifs we can use writeIndexedPixels to display the whole frame right?
For Jpgs I see that we're writing row by row with draw16bitBeRGBBitmap.
Wouldn't it be possible to grab the jpg data in such a way that we can use it in the writeIndexedPixels and basically treat it like a frame of a gif?
from arduino_gfx.
4-bit SD_MMC can play 22050 MP3 + 320x240 MJPEG over 15 FPS, is it already good enough?
https://github.com/moononournation/ESP32-LCDKit/blob/master/Mjpeg_MP3_JPEGDEC_DMA/Mjpeg_MP3_JPEGDEC_DMA.ino
from arduino_gfx.
I found that by changing the JPG size and buff size to 4096 from 2048 in JPGDEC.h (bitbank2/JPEGDEC) library source code we get an enormous increase in speed to display jpgs. I now have only ~0.14 seconds to display a quality 240*240 jpg from an SD card. I tried larger sizes and had a very small difference in performance, so i found that 4096 is optimal. I know that these libraries are meant to run on as many microcontrollers as possible, but with the ESP32 there is an order of magnitude more RAM than most others and by utilizing it both GIF playback and image rendering can be improved substantially.
I'm now going to shift attention to custom animations such as displaying live sensor data as a graph
from arduino_gfx.
from arduino_gfx.
But I said I can play 320x240 MJPEG at 15 FPS with MP3 simultaneously, or 30 FPS without MP3, that means only 0.033 seconds a frame.
from arduino_gfx.
I'd like to test that example later on as well, does this use both cores to achieve 30 FPS? One to fill the buffer and the other core to display?
I'll mention this change to bitbank2 as well, my findings have all been surface level; I'm sure the author would know of some additional ways to improve performance for more capable controllers like the ESP32
from arduino_gfx.
Related Issues (20)
- Versions newer than 1.3.5 do not compile for ESP32 in PlatformIO with Arduino framework HOT 2
- Underscore character issue. HOT 7
- esp32-s3 ili9486 basic problems HOT 8
- Turn off Auto Flush still flushes HOT 1
- General Question: Clipping HOT 1
- 16 bit i8080 interface ESP32s3+st7796 code,doesn't display anything HOT 5
- Code convertion from other lib HOT 2
- RP2040 1.28 WAVESHARE TOUCH LCD HOT 5
- Compilation error for BW16-kit HOT 10
- Waveshare display 3.5inches HOT 10
- Waveshare display 3.5inches #455
- #include <Arduino_GFX_Library.h> throws Error HOT 1
- Memory free about SpriteGif example HOT 2
- LVGL v9.1
- "MSB_16" redefined HOT 3
- No RM690B0 display driver for Lilygo T4-S3 (ESP32 Amoled Touch) HOT 3
- ESP32-4848S040C HOT 3
- When I use GC9107, colors are inverted. HOT 2
- Support for LilyGo T-Display S3 Long? HOT 4
- JC8048W550 ST7262 no display with V1.4.6 HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from arduino_gfx.