Skip to content

Bitmap image text is cut off on OLED display #82

@Chetan3321

Description

@Chetan3321

I am attempting to display a custom bitmap image of the text "कोरडे" (Koraḍe) on a monochrome OLED display using a microcontroller (e.g., Arduino/ESP32) and the generated C/C++ array.

The issue is that while the bitmap conversion tool's preview shows the image correctly, the output on the actual hardware display is cut off or truncated, resulting in an incomplete display of the text.

Expected Behavior
The full text "कोरडे" should be displayed on the OLED screen, matching the appearance in the conversion tool's preview.

Image

Current Behavior
The text is visibly cut off on the left side, only displaying part of the character 'को' and the rest of the word '.रडे'. It appears the image is not being displayed from the correct starting x-coordinate, or the total width is exceeding the displayable area and being clipped.

Image

Steps to Reproduce
Original Text: कोरडे

Conversion Tool Used: [Insert the name or link to the specific bitmap conversion tool you used, e.g., Image2LCD, LCD Assistant, etc.]

Preview Image (Working): [Reference the image issue1 - Copy.jpeg or attach it]

The preview image shows the text "कोरडे" correctly.

Hardware Output Image (Not Working): [Reference the image Issue2.jpeg or attach it]

The hardware output shows only "को.रडे" (with 'को' being partially cut off), indicating the beginning of the bitmap data is missing or out of bounds.

Environment Details
Please provide the following if possible:

Display Type: (e.g., 0.96" I2C/SPI OLED, SSD1306 controller)

Microcontroller: (e.g., Arduino Uno, ESP32, STM32)

Library Used: (e.g., Adafruit GFX, U8g2, etc.)

Bitmap C/C++ Array Declaration: (e.g., static const unsigned char image_data[] PROGMEM = { ... })

Display Code Snippet: (The function call you are using to display the bitmap, e.g., display.drawBitmap(x, y, image_data, width, height, color);)

Crucially, what X and Y coordinates did you use in the code? (e.g., display.drawBitmap(0, 0, ...) or display.drawBitmap(10, 20, ...)).

Possible Causes to Consider (Optional but helpful for the maintainer)
Incorrect X-coordinate: If the code is offsetting the image (e.g., display.drawBitmap(10, 0, ...)), it might be moving the image off-screen.

Incorrect Width/Height: The width and height declared in your code might not match the actual dimensions of the bitmap array.

Character Encoding Issue (Less Likely): While the characters are being generated as a bitmap correctly, sometimes character handling in the conversion tool or library can cause unexpected clipping.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions