Search Results

Search found 1267 results on 51 pages for 'rotate'.

Page 5/51 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Rotating Cursor According to Rotated TextBox

    - by j-t-s
    Hi All I have a TextBox that I allow my users to rotate. But what I would LOVE for my users is to have their Cursor rotate to the same angle that the TextBox was rotated at. For example, if they rotated the TextBox to 28°, then when the Cursor enters that TextBox the Cursor should also rotate itself to 28°. Any help at all will be greatly appreciated. Thank you :)

    Read the article

  • Circular shift operations in C++

    - by Elroy
    Left and right shift operators (<< and ) are already available in C++. However, I couldn't find out how I could perform circular shift or rotate operations. How can operations like "Rotate Left" and "Rotate Right" be performed? Rotating right twice here Initial --> 1000 0011 0100 0010 should result in: Final --> 1010 0000 1101 0000 An example would be helpful.

    Read the article

  • Rotating an object in OpenGL ES for iPhone [translate to origin --> rotate --> translate back is not

    - by ayanonagon
    I recently started working with OpenGL ES for the iPhone, and I am having a bit of trouble with it. I want to be able to rotate an object with your fingers. My problem is that I have my object placed at (0, 0, -3), and I would like to rotate it about its center. I know that I need to translate back to the origin, rotate, and then bring it back to the original place. I think I am facing a problem because I am using a matrix to keep track (?) of all of my rotations/translation/scaling etc, and I think it may be combining the operations in a way that order is not even considered (so the two translations would cancel each other). I just started learning OpenGL a day ago and am a complete newbie, so my assumption may be wrong. Here is the part of the in drawView that I am having trouble with: GLfloat matrix[16]; glGetFloatv(GL_MODELVIEW_MATRIX, matrix); glLoadIdentity(); glTranslatef(0, 0, 3); // bring to origin glRotatef(self.angle, self.dy, self.dx, 0); // rotate glTranslatef(0, 0, -3); // put it back in place glMultMatrixf(matrix); // save the transformations performed Help would be much appreciated, thank you!

    Read the article

  • Rotate MapView in Android

    - by Matthew B.
    I am writing an Android app where one of the features is that the map will rotate according to the compass (i.e. if the phone is pointing east, the map will be oriented so that the east side of the map is on top). Previous answers that I have found suggested over writing the onDraw() method in mapView, however, the api changed the method to final so it cannot be overwritten. As a result I have tried to overwrite the dispatchDraw() method like so: Note: -compass is a boolean that if true, rotate the view -bearing is a float variable that has the degrees that the view should rotate protected void dispatchDraw(Canvas canvas) { canvas.save(); if (compass) { final float w = this.getWidth(); final float h = this.getHeight(); final float scaleFactor = (float)(Math.sqrt(h * h + w * w) / Math.min(w, h)); final float centerX = w / 2.0f; final float centerY = h / 2.0f; canvas.rotate(bearing, centerX, centerY); canvas.scale(scaleFactor, scaleFactor, centerX, centerY); } super.dispatchDraw(canvas); canvas.restore(); }

    Read the article

  • Why when i rotate the image black borders appear? PHP GD

    - by EAGhost
    This code generates two images using GD and rotates one of them. When I rotate the image black borders begin to appear. Anyone have an idea of how to resolve this? imagefilledrectangle($im, 0, 0, 300, 400, $black); imagefilledrectangle($im, 1, 1, 298, 398, $grey); imagefilledrectangle($im, 49, 69, 251, 271, $black); imagefilledrectangle($im, 50, 70, 250, 270, $white); imagefttext($im, 13, 0, 90, 30, $black, $font_file, "Wind Direcction"); $source=imagecreatetruecolor(100, 100); imagefilledrectangle($source, 0, 0, 100, 100, $white); $values = array( 20, 30, // Point 1 (x, y) 50, 0, 80, 30, 65, 30, 65, 100, 35, 100, 35, 30 // Point 7 (x, y) ); imagefilledpolygon($source, $values, 7, $black1); $asd=imagerotate($source, $rotate, 0); imagecolortransparent($asd, $black); imageantialias($asd, true); $insert_x = imagesx($asd); $insert_y = imagesy($asd); if($rotate==0 || $rotate==90 || $rotate==180 || $rotate==270){ imagecopymerge ( $im , $asd , 100 , 130 , 0 , 0 , $insert_x , $insert_y , 100 ); } if($rotate==45 || $rotate==135 || $rotate==225 || $rotate==315){ imagecopymerge ( $im , $asd , 85 , 110 , 0 , 0 , $insert_x , $insert_y , 100 ); } imageantialias($im, true); header('Content-Type: image/png'); imagepng($im); imagedestroy($im); ?

    Read the article

  • UIView Animation: PartialCurl ...bug during rotate?

    - by itai alter
    Hello all, a short question. I've created an app for the iPad, much like a utility app for the iPhone (one mainView, one flipSideView). The animation between them is UIModalTransitionStylePartialCurl. shouldAutorotateToInterfaceOrientation is returning YES. If I rotate the device BEFORE entering the FlipSide, everything is okay and the PartialCurl is displayed okay. But if I enter the FlipSide and then rotate the device, while the UIElements do rotate and position themselves just fine, the actual "page curl" stays with its initial orientation. it just won't budge :) Is it a known issue? am I doing something wrong? Thanks!

    Read the article

  • Android Rotate Matrix

    - by jitm
    Hello, I have matrix. This matrix represents array x and y coordinates. For example float[] src = {7,1,7,2,7,3,7,4}; I need to rotate this coordinates to 90 degrees. I use android.graphics.Matrix like this: float[] src = {7,1,7,2,7,3,7,4}; float[] dist = new float[8]; Matrix matrix = new Matrix(); matrix.preRotate(90.0f); matrix.mapPoints(dist,src); after operation rotate I have array with next values -1.0 7.0 -2.0 7.0 -3.0 7.0 -4.0 7.0 Its is good for area with 360 degrees. And how do rotate in area from 0 to 90? I need set up center of circle in this area but how ? Thanks.

    Read the article

  • Windows Store App Visual Basic Rotate Object with code

    - by Ajay Raghav
    How to rotate an ellipse (or any other object) with VB code? In XAML, I designed an ellipse and easily rotated it from the properties (Transform - Rotate - Angle). When I am trying to do it with VB code, I cannot locate the rotate/angle property of that ellipse. So, I tried this: Dim Rotator As RotateTransform Rotator.Angle = 90 Ellipse1.RenderTransform = Rotator It didn’t work. It says: Unable to cast object of type 'Windows.UI.Xaml.Media.MatrixTransform' to type 'Windows.UI.Xaml.Media.RotateTransform'. I think I’m close to the right way. Please give me a push. Thanks

    Read the article

  • Rotate a drawed rectangle in flex

    - by Arif
    i wrote the following code for draw a rotate rectangle var s:UIComponent = new UIComponent(); s.graphics.lineStyle(1, 0x0000FF); s.graphics.drawRect(50, 50, 200, 200); s.rotation = 30; template.addChild(s); where template is a canvas. Its rotate nicely but the problem is the position is not in right place. i.e. it is not in (50,50) after rotate. How can i solve this problem? Thanks in advance.

    Read the article

  • Why doesn't C have rotate left/right operators?

    - by icepack
    A bit of a philosophical question, I suppose. Hope it belongs here. C language has the standard set of bit-wise operations, including OR, AND, XOR, SHIFT LEFT/RIGHT, NOT. Anyone has an idea why rotate left/rotate right isn't included in the language? These operators are of the same complexity as other bit-wise operators and normally require a single assembly instruction, like the others. Besides, I can think of a lot of uses for rotate operator, probably not less than, say, xor operator - so it sounds a bit strange to me that they aren't included in C along with the rest. Edit: Please stop suggesting implementations of rotation operators. I know how to do that and it's not what the question about.

    Read the article

  • Rotate a drawn rectangle in flex

    - by Arif
    i wrote the following code for drawing a rotate rectangle var s:UIComponent = new UIComponent(); s.graphics.lineStyle(1, 0x0000FF); s.graphics.drawRect(50, 50, 200, 200); s.rotation = 30; template.addChild(s); where template is a canvas. Its rotate nicely but the problem is the position is not in right place. i.e. it is not in (50,50) after rotate. How can i solve this problem? Thanks in advance.

    Read the article

  • Rotate a table in word

    - by Jake Pearson
    I have a word 2007 document in portrait mode. I have a table that is too wide to fit in 8.5" but would fit in 11". Is there a way to make just one page landscape? Or alternately is there a way to rotate a table 90 degrees?

    Read the article

  • Best software to rotate monitor picture 90 degrees

    - by Erik Vold
    What free software, preferably open source, will allow me to rotate the output to my widescreen monitor by 90 degrees? I had some software that came with my monitor to do this, called magiv view or something.. but it conflicted with tortoise svn in the context menu so I had to stop using it. Is there anything else that I can use or do?

    Read the article

  • Windows 7 Dell 1545 rotate screen and change wallpaper

    - by bizarrechaos
    I recently bought a second monitor and hooked it to my laptop. I like to put the monitor in portrait mode when coding and i can do this with igfx but i was wondering if there was a way to make a keyboard shortcut that will rotate my display 270 degrees and change my wallpaper to one that fits the 1050 X 1680 portrait resolution, and then have a key that rotates back to normal and resets my wallpaper? I have googled to no avail, I look forward to your answers. Thanks in advance, bizarrechaos

    Read the article

  • rotate image with php - any degree

    - by Luis
    How to rotate an image with PHP, any degree, without having the filled space? For instance, if I rotate an image 10 degrees, the image rotates fine but the container around (square) gets filled with black. Is it possible to get rid of this, when for example merging 2 images?

    Read the article

  • C# rotate a string 180 degrees

    - by Tom
    Hi im having a few problems rotating a string, i found that you need graphics.rotate() but when i change the rotation, i cannot even see the string. It appears the pivot point has completely thrown me. Also i saw an example with transform but i decided i did not need this? If my string was a graph label, reading top to bottom and i needed to rotate it 180 degrees so that it read bottom to top, how would i do this? Thanks in advance

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >