Vertical image upload possible bug


#1

I been now trying to use Wappler and so far I am liking it, but I encountered I think a new bug when uploading images with Wappler, for some reason vertical images that I have on my hard drive show in landscape orientation, and rotated please see the screenshots:

The original files on the harddrive:


Capture004

When uploading:


#2

Hello,
In the load image step in server connect there is an auto orientation option - have you enabled it?


#3

I enabled it but the same happens i disabled now again, it seems to only happen with pictures from my iphone downloaded to my computer


#4

Also when I add resize and crop I get an internal 500 error, if I remove one of them it works

the error with the debug on is the following:

{code: 0, file: "/home1/bbbn9su/privatedomain.com/dmxConnectLib/lib/image/Processor.php",…}
code: 0
file: "/home1/bbbn9su/privatedomain.com/dmxConnectLib/lib/image/Processor.php"
line: 406
message: "value is out of range."
trace: "#0 /home1/bbbn9su/privatedomain.com/dmxConnectLib/lib/image/Processor.php(112): lib\image\Processor->cy(-2, 300)↵#1 /home1/bbbn9su/privatedomain.com/dmxConnectLib/modules/image.php(140): lib\image\Processor->crop(0, 'middle', 300, 300)↵#2 /home1/bbbn9su/privatedomain.com/dmxConnectLib/lib/App.php(159): modules\image->crop(Object(stdClass), '')↵#3 /home1/bbbn9su/privatedomain.com/dmxConnectLib/lib/App.php(128): lib\App->execSteps(Object(stdClass))↵#4 /home1/bbbn9su/privatedomain.com/dmxConnectLib/lib/App.php(98): lib\App->execSteps(Array)↵#5 /home1/bbbn9su/privatedomain.com/dmxConnectLib/lib/App.php(71): lib\App->exec(Object(stdClass))↵#6 /home1/bbbn9su/privatedomain.com/dmxConnect/api/Security/profile.php(8): lib\App->define(Object(stdClass))↵#7 {main}"

#5

I had a very similar issue when using BlueImp’s jQuery File Upload plugin for PHP (This is a very clever and powerful upload script). There was an orientation issue with iPhone images. Hopefully the clever people at Wappler can investigate :grin:


#6

This is a whole different issue.
Most probably you set a crop value bigger than the age dimensions.


#7

This is IOS issue not wappler
same issue happen on another development tool im using


#8

Yes, but we have added a fix for this in the image processor scripts. I am going to check if they have been implemented in Wappler.


#9

This sounds like a problem which was discussed here.


#10

Hi Teodor,
What does the auto-orientation option do?


#11

It ignores such issues with bad exif data from smartphones and uploads the image without rotating it.


#12

Thanks. Does it strip out the EXIF data? By ‘bad’ data, do you mean the data which causes the image to be rotated?


#13

We just ignore the data in the EXIF, we are not removing it.


#14

@lsadesl please zip and send me your local copy of: /dmxConnectLib/lib/image/Processor.php as a private message.


#15

That’s useful to know.

I would have thought it would still mean that images won’t necessarily appear as expected. Eg an image taken with an iPhone in landscape orientation only appears ‘correctly’ when the phone is held in portrait orientation because of the EXIF information. If the software displaying the image doesn’t read this data, the image wil appear to be rotated (whereas it’s actually shown as it was originally taken).

Anyway, I haven’t experimented with this feature yet, so I don’t really know the results.


#16

I don’t get your point, but i already explained that our script ignores the exif data that causes this.


#17

My point was (thought I could be wrong), that if you ignore EXIF data, images may appear the wrong the way round.


#18

Hi Teodor,

Sent you the file.

Thank you for looking into this.