Take photo in landscape orientation

482 views
Skip to first unread message

Scott Stevenson

unread,
Dec 14, 2011, 2:04:56 AM12/14/11
to Tasker
Taking a photo through Media->Photo doesn't seem to care what the
orientation of the phone is as would the stock camera app. It always
stores the photo as portrait orientation. I need it to know that the
phone is sideways and store the photo as a landscape. Or be able to
rotate the photo after it is taken automatically. In my use case,
photos will always be landscape mode.

Appreciate any help

BossMan

unread,
Dec 14, 2011, 4:10:16 AM12/14/11
to tas...@googlegroups.com
The stock camera app not only takes pictures, but also adds additional information, e.g. location, orientation etc. in the Exif data. You could try using e.g. ExifTool Perl library ( http://www.sno.phy.queensu.ca/~phil/exiftool/) combined with SL4A/Perl and update the orientation tag in every photo taken (or maybe - in any taken in the horizontal position).

BR,
A.




Pent

unread,
Dec 14, 2011, 4:14:03 AM12/14/11
to Tasker

Stores as landscape on my Nexus S and N1 (and my old G1).
Unfortunately, the camera handling (especially orientation) is very
messy in Android.

At some point you'll be able to detect the orientation of the phone at
the time the photo is taken and rotate the image yourself, but that's
not possible yet (at least, with Tasker inbuilt features).

Pent

Pent

unread,
Dec 14, 2011, 4:20:04 AM12/14/11
to Tasker
BTW, what's your phone and Android version ?

Pent

scstev77

unread,
Jan 25, 2012, 12:05:16 AM1/25/12
to Tasker
Sorry, I thought I'd get an email from the group, guess I didnt set it
up right.

I have a Motorola Photon Android 2.3.4

Thanks. Also I'd vote for ability to choose smaller photos... I am
using Tasker with FolderSync plug in to take time lapse photos from a
fixed location on solar power and post to web. For now, a crond perl
script is rotating and resizing, but smaller photos would allow me to
take them more often.


On Dec 14 2011, 4:14 am, Pent <supp...@apps.dinglisch.net> wrote:
> > Taking aphotothrough Media->Photodoesn't seem to care what the
> > orientation of the phone is as would the stock camera app.  It always
> > stores thephotoas portrait orientation.  I need it to know that the
> > phone is sideways and store thephotoas a landscape.  Or be able to
> > rotate thephotoafter it is taken automatically.  In my use case,
> > photos will always be landscape mode.
>
> Stores as landscape on my Nexus S and N1 (and my old G1).
> Unfortunately, the camera handling (especially orientation) is very
> messy in Android.
>
> At some point you'll be able to detect the orientation of the phone at
> the time thephotois taken and rotate the image yourself, but that's

JamesA

unread,
Dec 22, 2013, 1:30:59 PM12/22/13
to tas...@googlegroups.com
Hey Scstev77... I realize that this is an old post, but if you're still following this thread, it would great to get a copy of the perl script you're using.  I am actually doing something very similar - have an old Evo on a small solar panel out in a remote location posting-one photo to the web daily.  Its working well except for the image rotation issue.  I'm using Tasker ver 4.2u3M that has some image rotation capabilities but I can't get them to work.  

The other totally unrelated issue I'm having is one that you may have experience with and is related to the solar panel.  I've got an external battery in between the panel and the phone, but the battery (which apparently has some protection circuitry keeps getting errors when the solar charge drops off).  Do you use a backup battery? And are there any that you recommend that avoid this issue?

JamesA

unread,
Dec 22, 2013, 2:17:17 PM12/22/13
to tas...@googlegroups.com
EDIT - OK I found that I can get the image rotate in Tasker 4.2 to work on small images, but not the original 2560x1920 image... these images are about 600K... not huge by today's standards... am wondering if there's a phone memory issue (theres 300MB Free! in system RAM) or a limit in Tasker related to image size (per the log, the error is on loading the large image... it doesn't get that far...)

Bob Hansen

unread,
Dec 22, 2013, 3:00:47 PM12/22/13
to tas...@googlegroups.com
It is likely a memory problem. A 2560x1920 image might by 600k compressed, but when uncompressed it could easily be several hundred megabytes depending upon the color depth. Then in order to rotate it, it would be necessary to create a second image in memory that is that same size. The total could easily exceed 300Mb. 

Pent

unread,
Dec 23, 2013, 2:39:17 AM12/23/13
to tas...@googlegroups.com

EDIT - OK I found that I can get the image rotate in Tasker 4.2 to work on small images, but not the original 2560x1920 image... these images are about 600K... not huge by today's standards... am wondering if there's a phone memory issue (theres 300MB Free! in system RAM) or a limit in Tasker related to image size (per the log, the error is on loading the large image... it doesn't get that far...)


As Bob says, they're much, much larger uncompressed. Each app in Android has a limit on 'working memory', often 16MB, depends on ROM.

Pent

JamesA

unread,
Dec 24, 2013, 9:13:37 AM12/24/13
to tas...@googlegroups.com
Interesting.  I'll try on different phones (ICS & JB 4.2 ) with more memory.  However, in a related -more important- discovery... I've found that if I take Discreet OFF the photo is saved in the correct orientation!  Glad I found this but gotta say one wouldn't expect selection of the the "discreet" option to change (or override) the photo orientation!

JamesA

unread,
Dec 26, 2013, 12:40:40 PM12/26/13
to tas...@googlegroups.com
this continues... at least on the two phones I'm testing on an old LG LG MOTION 4G (MS770) and an Sprint Evo 4G (both running ICS) I've determined that the screen actually has to be on for the orientation to be correct in the saved photo... weird... unfortunately on the LG the screen on task is unavailable... will have to try on the EVO next time i retrieve it.

Scott S

unread,
Apr 8, 2014, 2:21:53 PM4/8/14
to tas...@googlegroups.com
I notice Android/Tasker doesn't recognize the default Camera app in Landscape using State > Display > Orientation > Landscape. However, I can use State > Sensor > Orientation > Left Side.

Slava Leonov

unread,
Jun 8, 2017, 6:15:56 PM6/8/17
to Tasker
It's been years but the problem hasn't been fixed it appears.  The only way Tasker can take a photo in landscape is to have "Discreet" box in "Take Photo" unchecked, keep the screen on, and phone unlocked.  Then photo preview appears, gets properly oriented, and a photo is taken in landscape.  Otherwise, photos are taken in portrait.

I can't seem to rotate photos with "Rotate Image" either.

Did anyone manage to solve this?
Reply all
Reply to author
Forward
0 new messages