lovyan03 / LovyanGFX

SPI LCD graphics library for ESP32 (ESP-IDF/ArduinoESP32) / ESP8266 (ArduinoESP8266) / SAMD51(Seeed ArduinoSAMD51)
Other
1.03k stars 189 forks source link

DrawJpgFile from SD #488

Closed Julien83 closed 5 months ago

Julien83 commented 5 months ago

Hello when i try to draw jpg from SD card by this line

static LGFX lcd; lcd.drawJpgFile(SD, "/test.jpg");

i have this error

no matching function for call to 'lgfx::v1::LGFX::drawJpgFile(fs::SDFS&, const char [10])' lcd.drawJpgFile(SD, "/test.jpg");

Can you help me ?

tobozo commented 5 months ago

hi,

make sure to include <SD.h> before <LovyanGFX.hpp>

Julien83 commented 5 months ago

Thank you, all right it works