Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
I am trying to develop an app similar to paint app.
I want allow user to perform redo or undo operations over canvas.
I searched a lot, but dint find any example that explains about redo
and undo operations for Circle, Rectangle etc.
most of the tutorials explain redo and undo for Line.
Any help will be appreciated.
Store every operation in a list, then if you want to undo something just remove the last thing you put into the list. A linkedlist or a stack would work.
Pseudocode
Stack<Action> operations=new Stack<Action>();
Stack<Action> redos=new Stack<Action>();
Every time user have done something do
operations.push(new Action(actiontype,ccoordinates));
for undo
redoes.push(operations.pop());
to redo
operations.push(redos.pop());
and in your onDraw() method you draw everything thath is in operations...
Related
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
In the game i need to the user to draw a figure, for example a rectangle, and the game has to recognize the figure. How can i do this?
Thanks!
This sounds like you would want to use a Neural Network. If you don't know what that is: It is basically an Artificial Brain which can do simple tasks like classifying (recognizing) shapes. It's really easy to do with tensorflow, since it's easily integratable into Android: https://www.tensorflow.org/mobile/android_build
Then, you would train your classifier to differenciate between Circle, Rectangle, Triangle and more. For this, you should draw some rectangles and triangles in your app, save them as images and label them yourself with what is in them. Then you can use those images with TensorFlow to train your AI to recognize images the user draws.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
How do you show the user, how to use the app. Is there a tool or something which allows the user to learn how to use it, like a tutorial.
Or what would you do?
By the way, in my app, the user just needs to understand which button needs to be clicked. Basically, he must pick the correct button according to the background color.
To show or introduce your app to the user is called as show casing your app/views(we can say aka tutorial).
You can make your own showcasing animations but there are some libraries for that purpose
ShowCaseView
spotlight(my favourite one)
You can easily implement that by reading some more stuff about showcasing app or views
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I am working on a language Learning android app. I want to include a feature on how to write a particular letter of a particular language.
So, the general idea is when a user clicked on a letter say 'A',a pop up activity appears and A is written with a pencil, i.e., sort of showing the user how to write A.
Any one had idea how i can implement this in android?
thanks
You need to draw letter on canvas, using Android drawing APIs. You can do it in two steps:
First draw letter, and save all drawing objects.
Second, draw again (replay) using previously saved objects.
There is an other way which will be easy but it will require alot of effort by designer. You will have to create gif files for each letter from which you can animation.
Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
let's say I have a 3d car model displayed using GLSurfaceView in Android. This model consists of many components, is that possible to control each of them or make each of them response to touch events individually? for example, if I want to select one wheel, what I need to do is touch the wheel.
I think you are looking for ray picking or ray intersection.
This answer has a link to a iOS sample/video which I believe is what you are after.
https://gamedev.stackexchange.com/questions/12360/how-do-you-determine-which-object-surface-the-users-pointing-at-with-lwjgl/12367#12367
Another related SO question:
Implementing Ray Picking
That should get you started on what you need to do.
Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 9 years ago.
Improve this question
I am new to android app development. I am trying to develop an app which will obtain some data from a web service and i need to draw this on bitmap.But this text is not a constant text. It may change. Is it possible to draw such a changing text in bitmap?
Kindly help me as i am new to this area.
To answer your question, yes it is possible. However, your application will have to keep checking for any changes made, for them to be updated in the bitmap. It might not be too efficient. For web services, make sure you use a background process. (AsyncTask)