Bodmer/TJpg_Decoder

TJpgDec.getJpgSize

oneandonlyonebutyou opened this issue · 4 comments

I do not know how to convert the image to binary
I used the web-tool provided for diff image the size is zero ...

TJpgDec.getJpgSize(&w, &h, img, sizeof(img));

what is the specification of the image, and why it is zero ?

08:48:20.252 ->  Size of: 2446
08:48:20.286 -> Width = 0, height = 0
08:48:20.321 -> 0 ms

I now use the tool and instructions detailed here.

Jpeg file arrays should start with the marker values: 0xFF,0xD8,0xFF,

@Bodmer Thank you but I still have the same issue
The array does not start with :

 file arrays should start with the marker values: 0xFF,0xD8,0xFF,

image

https://www.cleanpng.com/png-candle-birthday-cake-clip-art-burning-candles-85642/

A PNG format file cannot be decoded with a jpeg decoder. Convert the png to a jpeg first with an image handling program like GIMP or MS Paint. Alternatively use a PNG decoder library.

You can read about image formats here:
https://en.wikipedia.org/wiki/Image_file_format