Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

some suggestions #58

Closed
lixy123 opened this issue Jan 22, 2021 · 7 comments
Closed

some suggestions #58

lixy123 opened this issue Jan 22, 2021 · 7 comments
Labels
enhancement New feature or request

Comments

@lixy123
Copy link

lixy123 commented Jan 22, 2021

  1. Because there is no corresponding API, it is difficult to calculate the word wrap. Can you provide the ability of automatic line wrap In the display string function?
  2. Can you provide the API function of drawjpg() or drawbmp() ?

This is another API about ink screen project, With the ability to read and display JPG, BMP, PNG,
for reference
https://github.com/m5stack/M5EPD/blob/main/src/M5EPD_Canvas.cpp

@aceisace
Copy link

I agree. This project has some great potential. It would be awesome to add native support to display a BMP file e.g. by downloading it as a BMP file or simply downloading it's buffer.

@vroland
Copy link
Owner

vroland commented Jan 23, 2021

Those would be indeed nice to have. I'm planning on implementing a Arduino-Style layer on top of the C API that implements more convenience functions. This is where those would fit in.
I can't give a timeline for that though. In the meantime, if you want an example for jpeg decoding you can have a look at the mpd example.

@lixy123
Copy link
Author

lixy123 commented Jan 25, 2021

Thanks for the sample code of parsing and displaying jpg image. I'll take time to try it. However, it should be better if this code is in the API library. I don't know if there is an API for screen coordinate rotation.

@vroland vroland added the enhancement New feature or request label Jan 25, 2021
@vroland
Copy link
Owner

vroland commented Jan 25, 2021

Yes, that would make sense. I'll mark it as a possible enhancement.

@martinberlin
Copy link
Sponsor Collaborator

martinberlin commented Mar 25, 2021

Hi Valentin,
Small suggestion (Since I don't think makes sense to open an Issue for this)
demo Example
https://github.com/vroland/epdiy/blob/master/examples/demo/main/main.c#L23

Does not compile for EPD_WIDTH <1000 since it does not find the file:
#include "firasans_12pt.h"

The correct file name is firasans_12.h
As a side comment I have a demo about downloading a BMP over WiFi and displaying it using 8 grayscales:
https://github.com/martinberlin/cale-idf/blob/master/main/cale-grayscale.cpp

It may serve as an example of how to download a Bitmap (supports 1, 4 and 8 bits depth) and write it pixel by pixel to the EPD buffer. This could perfectly work with EPDiy you just have to update display initialization. In Cale-idf project I use also EPDiy but still the older version.

martinberlin added a commit to martinberlin/epdiy-rotation that referenced this issue Mar 25, 2021
@DavidM42
Copy link
Contributor

I think those are great suggestions too 👍 .
One more nice thing would be to add a return boolean if the wrapped text fits onto the area/display. This could be coupled with some kind of pagination feature, so any amount of long text can be displayed via pages

@martinberlin
Copy link
Sponsor Collaborator

Closing here since we already have another thread on suggestions #31
Please add any further suggestions there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants