Questions tagged [image-rotation]

Image rotation is performing a geometric rotation with certain angle on a particular image.

Image rotation is performing a geometric rotation with certain angle on a particular image. An image can be rotated by a positive angle or negative angle, which will rotate the image clockwise or counterclockwise. Rotating an image by 360 degrees or -360 degrees will actually result in the same image as the original image, while rotating on 180 or -180 degrees will display an inverted copy of the original image.

844 questions
17
votes
6 answers

How to rotate image and save the image

In my application i have an image in a div,a button. I want to rotate the image displayed and save the rotated image when i clicked on the button using jquery. I already used the code: http://code.google.com/p/jquery-rotate/ and jquery…
galtech.Mariya
  • 223
  • 2
  • 3
  • 8
15
votes
6 answers

Android CameraX image rotated

I have followed Google CameraX code lab to implement custom camera. Camera preview is fine but when i take image after image capture image is rotated. I am taking image in portrait mode but saved image is in landscape. Here is the method to…
14
votes
3 answers

How to Determine and Auto-Rotate Images?

I have bunch of images, among them some of the images have to be rotated. Sample: I want to rotate this image 90° counter-clockwise. I Googled to know how can I rotate an image and found many links and SO threads. But how can I determine if the…
Tapas Bose
  • 28,796
  • 74
  • 215
  • 331
13
votes
1 answer

When using node sharp package to resize image and upload to s3 it is rotated

I am using this node package: https://www.npmjs.com/package/sharp I use it to resize an image and then upload it to amazon S3. Most images are find but some of them (I assume based on aspect ratio) get rotated. Is there a way to prevent this or a…
jaget
  • 2,149
  • 6
  • 21
  • 29
12
votes
5 answers

How can I rotate a transparent png by 45 degrees using imagemagick and keep the new image transparent?

I have a 16x16 transparent png and I did convert -rotate -45 a.png b.png This rotated it and created a new image b.png which is of size 22x22 and which when I use against a background shows the original image (16x16) rotated with the underlying…
molicule
  • 5,481
  • 3
  • 29
  • 40
12
votes
4 answers

How To Rotate Image By Nearest Neighbor Interpolation Using Matlab

My Plain Code without interpolation: im1 = imread('lena.jpg');imshow(im1); [m,n,p]=size(im1); thet = rand(1); m1=m*cos(thet)+n*sin(thet); n1=m*sin(thet)+n*cos(thet); for i=1:m for j=1:n t =…
12
votes
1 answer

Rotating a bitmap using JNI & NDK

Background: I've decided that since bitmaps take a lot of memory which can cause out-of-memory errors easily, I will put the hard, memory consuming work on C/C++ code . The steps I use for rotating a bitmap are: read bitmap info…
android developer
  • 114,585
  • 152
  • 739
  • 1,270
11
votes
1 answer

How to rotate an layer at a specific anchor point without a skip?

I want to rotate a layer with an image at the top left corner, and not the center. According to the docs I set the anchorPoint property to [0, 1]. The view rotates in my example by 50°, but before it starts to animate, the view jumps to another…
Rafael Bugajewski
  • 1,702
  • 3
  • 22
  • 37
11
votes
3 answers

jQuery Rotate - IE7 & IE8 Issues

I am using Jquery Rotate to rotate an image around a meter, and it works great but in IE7 and IE8 it gets pushed up about 200 pixels and has a black stroke/border around the image. I am using jQueryRotate3.js which has it working, but the position…
Xtian
  • 3,535
  • 11
  • 55
  • 91
10
votes
1 answer

Firebase Storage image gets rotated

In my app I prompt the user to capture an image. The users camera activity starts on a buttonClick and the user gets the option to use the camera to capture an image. This image saves on the users phone. The image is then uploaded to firebase…
firozaqiwu
  • 195
  • 2
  • 10
10
votes
1 answer

3D image rotation in python

I have the following image I1. I did not capture it. I downloaded it from Google I apply a known homography h to I1 to obtain the following image I2. I want to assume that a camera has taken this above shot of I2. I have found the camera matrix of…
RaviTej310
  • 1,635
  • 6
  • 25
  • 51
10
votes
1 answer

Webcam - Camera Preview rotates wrong way

I would like your help please on a WebCamera problem. I've used a library available from Nuget; WebEye.Controls.Wpf.WebCameraControl (version 1.0.0). The URL is https://www.nuget.org/packages/WebEye.Controls.Wpf.WebCameraControl/ The article and…
jova85
  • 317
  • 2
  • 10
10
votes
1 answer

Image loses quality with cv2.warpPerspective

I am working with OpenCV 3.1 and with Python. My problem comes when I try to deskew (fix the tilt of) an image with text. I am using cv2.warpPerspective to make it possible, but the image loses a lot of quality. You can see here the original part…
Chuck Aguilar
  • 1,998
  • 1
  • 27
  • 50
10
votes
4 answers

Rotate a buffered image in Java

I am trying to rotate a buffered image in java. Here is the code I am using: public static BufferedImage rotate(BufferedImage bimg, double angle) { int w = bimg.getWidth(); int h = bimg.getHeight(); Graphics2D graphic =…
Zugor
  • 133
  • 1
  • 2
  • 9
10
votes
4 answers

Rotating Image with AffineTransform

I have got class called Airplane. Inside this class i have got variable img which is a BufferedImage type. What is more i have got class WorldMap which overrides function paintComponent(Graphics g): @Override public void paintComponent(Graphics g)…
user2410128
1
2
3
56 57