# Rotate circle around it´s own center

**URL:** <https://discourse.processing.org/t/rotate-circle-around-it-s-own-center/12937>\
**Category:** Coding Questions\
**Created:** [July 24, 2019, 12:04am UTC](https://discourse.processing.org/t/rotate-circle-around-it-s-own-center/12937 "2019-07-24T00:04:07Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sweetiefraise](https://avatars.discourse-cdn.com/v4/letter/s/a88e4f/32.png) [@Sweetiefraise](https://discourse.processing.org/u/Sweetiefraise)\
**Post date:** [July 24, 2019, 12:04am UTC](https://discourse.processing.org/t/rotate-circle-around-it-s-own-center/12937/1 "2019-07-24T00:04:07Z")

</div>

I want to rotate the eyes of this bear inside de white circles, so I want to know what I shoould put there

This part specifically:

```auto
//left eye
fill (#000000);
strokeWeight(6);
stroke (#050302);
circle (320, 190, 50);
fill (#FFEEE8);
circle (325, 175, 20);
//right eye
fill (#000000);
strokeWeight(6);
stroke (#050302);
circle (190, 190, 50);
fill (#FFEEE8);
strokeWeight(6);
stroke (#050302);
circle (196, 175, 20);

```

HERE´S THE FULL CODE

```auto
float ang;

void setup() {
  size (500, 500);
  background (#F2D3FF);
  smooth();
}

void draw() {
  background (#FFAAAB);
  fill(255);

  //--------------------------------
  //-----------------------------
  fill (#834830);
  strokeWeight(6);
  stroke (#713E29);
  circle (370, 70, 100);
  fill (#834830);
  strokeWeight(6);
  stroke (#713E29);
  circle (140, 70, 100);
  //orejitas
  fill (#FFAAAB);
  strokeWeight(6);
  stroke (#713E29);
  circle (370, 70, 50);
  fill (#FFAAAB);
  strokeWeight(6);
  stroke (#713E29);
  circle (140, 70, 50);

  //
  fill (#834830);
  strokeWeight(8);
  stroke (#713E29);
  circle (250, 250, 400);
  fill (#FFEEE8);
  strokeWeight(6);
  stroke (#050302);
  circle (190, 190, 90);
  fill (#FFEEE8);
  strokeWeight(6);
  stroke (#050302);
  circle (320, 190, 90);

  //------------------
  //linea nariz
  line(253, 320, 253, 250 );
  fill (#3E2014);
  strokeWeight(3);
  stroke (#2C160E);
  ellipse (253, 250, 100, 50);
  fill (#27160F);
  strokeWeight(8);
  circle (230, 250, 10);
  strokeWeight(8);
  circle (270, 250, 10);
  arc(253, 320, 80, 8, radians(0), radians(180));
  //lengua
  fill(#C65254);
  arc(253, 330, 50, 50, radians(0), radians(180));

  //-----------------------------------------------------------------------------------------------------
  //--------------------------------
  //noStroke();
  // ellipse(190,190,50,50);
  //ang = ang+0.02; //ángulo girado
  //translate(250,90); //traslada el origen de coordenadas para girar dentro del lienzo
  //rotate(ang-2); //gira el objeto el ángulo girado

  //-----------------------------------------------------------------------------------------------------
  //ojitos izq---------------
  fill (#000000);
  strokeWeight(6);
  stroke (#050302);
  circle (320, 190, 50);
  fill (#FFEEE8);
  circle (325, 175, 20);
  //ojitos derecho
  fill (#000000);
  strokeWeight(6);
  stroke (#050302);
  circle (190, 190, 50);
  fill (#FFEEE8);
  strokeWeight(6);
  stroke (#050302);
  circle (196, 175, 20);
}

```

---

<div class="post-metadata">

**Author:** ![kll](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/kll/32/964_2.png) [@kll](https://discourse.processing.org/u/kll)\
**Post date:** [July 24, 2019, 12:44am UTC](https://discourse.processing.org/t/rotate-circle-around-it-s-own-center/12937/2 "2019-07-24T00:44:37Z")

</div>

please repair above code posting.  
use in processing IDE [ctrl][t] for a readable format,  
and post it here inside the

```auto
</> code tag

```

looks like  
```  
type or paste code here  
```

---

<div class="post-metadata">

**Author:** ![jeremydouglass](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/jeremydouglass/32/20_2.png) [@jeremydouglass](https://discourse.processing.org/u/jeremydouglass)\
**Post date:** [July 28, 2019, 4:54pm UTC](https://discourse.processing.org/t/rotate-circle-around-it-s-own-center/12937/3 "2019-07-28T16:54:49Z")

</div>

Reformatted with forum \</\> button so that people can read the code in your question.

Did you solve this? Do you want the eyes:

1. rotated once, or
2. spinning all the time, or
3. following the mouse pointer?
