Circular Region

Problems with Canvas, OpenGL, etc...

Circular Region

Postby 8arcena » Fri Dec 10, 2010 9:42 am

Hello, I'm trying to do a create a circular Region.
If you look at the API, you can see that you can easily create regions out of Rect

android.graphics.Region
Region(Rect r)

Is there a way to create a Region out of a circle by specifying its origin coordinates and radius?
Can you create a circle region out of a Path that contains a circle?
I've looked all over google.
I want to know this to implement an analouge style on screen d-pad for a game. I know i can just calculate the
event's x and y values and look at their distances from the center of the circle, but i think a circular region could be used to create complex regions that i might use later on.
8arcena
Freshman
Freshman
 
Posts: 2
Joined: Fri Dec 10, 2010 9:34 am

Top

Return to Android 2D/3D Graphics - OpenGL Problems

Who is online

Users browsing this forum: No registered users and 2 guests