Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-3316] No way to compress image before posting?

GitHub Issuen/a
TypeBug
PriorityLow
StatusClosed
ResolutionWon't Fix
Resolution Date2017-07-19T19:04:52.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsiOS
Labelsphoto, upload
ReporterBrian
AssigneeIngo Muschenetz
Created2011-04-15T03:41:59.000+0000
Updated2017-07-19T19:04:52.000+0000

Description

There doesn't seem to be a way to compress an image or lower its quality before posting it to a remote server. The images taken by the iphone 4 are incredibly big and need to be compressed. In Obj-C I would just do the following:

UIImageJPEGRepresentation(photo, 0.3);

We need something similar for titanium. This is a big showstopper for anyone trying to have upload image capabilities in their app. Very surprised no one else has escalated this issue...or is their a workaround available?

Comments

  1. Brian 2011-04-15

    Looks like you have modify the Titanium source code to do this...which really isn't an acceptable solution. See this post:

    http://developer.appcelerator.com/question/56181/image-compression"> http://developer.appcelerator.com/question/56181/image-compression

  2. pbreitenbach@gmail.com 2011-12-28

    Uploading photos is extremely common. This would be a much better way to do it than some of the solutions I've seen. Please fix!
  3. Lee Morris 2017-07-19

    Closing ticket due to time passed and lack of progress for a number of years. Please open a new ticket if there are any problems.

JSON Source