Advertisement:

Author Topic: Problems with autoRotate function  (Read 3191 times)

bodocvl

  • Newbie
  • *
  • Posts: 19
Problems with autoRotate function
« on: December 12, 2015, 01:38:07 am »
Hi,

The function still missing lots of pictures made with some mobile devices. (samsung, some iphones, etc).
When you take a portrait pictures, the functions can't seems to know how to autorotate it as such because the picture is uploaded in landscape mode (flipped 90 degrees).

Can somebody take a look at open classifieds auto rotate function? They made this work (but the rest of the script is not nice at all).

Thanks

dev101

  • Osclass Hero
  • Hero Member
  • *
  • Posts: 2155
  • osclass.work
Re: Problems with autoRotate function
« Reply #1 on: December 12, 2015, 03:55:30 am »
Some phones do not store image orientation data, and Osclass cannot do correction without it.
Blame it on manufacturer of the phone(s).

Regards,
dev101

bodocvl

  • Newbie
  • *
  • Posts: 19
Re: Problems with autoRotate function
« Reply #2 on: December 12, 2015, 01:23:02 pm »
Some phones do not store image orientation data, and Osclass cannot do correction without it.
Blame it on manufacturer of the phone(s).

Regards,
dev101

No, the photos does have exif orientation data, it's the function's fault.
On osclass it's not working, on open classifieds it's working.

Same photo, using imagick.

dev101

  • Osclass Hero
  • Hero Member
  • *
  • Posts: 2155
  • osclass.work
Re: Problems with autoRotate function
« Reply #3 on: December 12, 2015, 01:43:31 pm »
Sorry, it does not make any sense. Please upload your original image somewhere so I can test.

bodocvl

  • Newbie
  • *
  • Posts: 19
Re: Problems with autoRotate function
« Reply #4 on: December 12, 2015, 01:48:07 pm »
Sorry, it does not make any sense. Please upload your original image somewhere so I can test.

I PM-ed you the original picture.

bodocvl

  • Newbie
  • *
  • Posts: 19
Re: Problems with autoRotate function
« Reply #5 on: December 12, 2015, 02:08:21 pm »
Sorry, it does not make any sense. Please upload your original image somewhere so I can test.

I PM-ed you the original picture.

Another problem I see with GD for autoRotate function:

We have:
if(isset($this->_exif['Orientation'])) {
                    switch($this->_exif['Orientation']) {...


But there is no exif reading, so the functions seems to not know what to do with the picture.
exif_read_data is not called at all for GD



arcsales

  • Full Member
  • ***
  • Posts: 192
Re: Problems with autoRotate function
« Reply #6 on: January 21, 2016, 11:00:50 am »
Im not a programmer however it seems to be very easy and simple to create a function that can flip and/or rotate any image and this can be done on user side while the user is uploading his images...does that make any sense to you guys?

ala

  • Full Member
  • ***
  • Posts: 213
Re: Problems with autoRotate function
« Reply #7 on: January 21, 2016, 03:09:10 pm »
it seem like this picture can rotation 180 degrees, it us JS  and alot of classified websites has been update to this upload style

arcsales

  • Full Member
  • ***
  • Posts: 192
Re: Problems with autoRotate function
« Reply #8 on: January 27, 2016, 06:35:51 pm »
@ala yes that is what i was asking for.
Also if possible to reorder the images and change the primary image.
I dont know how nobody so far have been thinking on this.

garciademarina

  • Administrator
  • Hero Member
  • *****
  • Posts: 974
Re: Problems with autoRotate function
« Reply #9 on: January 27, 2016, 06:42:31 pm »
Hi there,

Osclass 3.6.0 has been released and fixes the autorotate issues.

Preview and final uploaded images are rotated correctly, you still need exif support (http://php.net/manual/en/book.exif.php) or imagemagick php extension.

markuspmeyer

  • Newbie
  • *
  • Posts: 2
Re: Problems with autoRotate function
« Reply #10 on: May 01, 2016, 05:21:39 pm »
Hi
Still facing the autorotate problem:

Browsers: all
osclass: 3.6.1
Image lib php extension: imagemagic
Theme: zara 1.0.8


Would be nice to provide user with a rotate function in item_edit and item_post similar UI as for deleting an image. So it is possible to handle all kind of wrong exif information. Still better to enable for the user than post a "wrong" rotated image for some reasons.

Cheers,
Markus






jazepsmalta

  • Newbie
  • *
  • Posts: 19
Re: Problems with autoRotate function
« Reply #11 on: March 23, 2019, 06:02:05 pm »
If we upload photos from Apple phone, pictures automatically rotates on 90 degrees. Somebody have solution of this issue?

steve.ram

  • Newbie
  • *
  • Posts: 8
Re: Problems with autoRotate function
« Reply #12 on: June 07, 2019, 02:38:00 pm »
Having the same issue, any one found the solution?

steve.ram

  • Newbie
  • *
  • Posts: 8
Re: Problems with autoRotate function
« Reply #13 on: June 17, 2019, 01:39:36 am »
Using last version of Osclass but still have this problem, any help guys?