I am kind of new to the onDraw so i don't know how to go around this problem.
I want to draw a image at this location (just so i can try the rest myself). These locations are off the ontap and * the drawables width and height. This code is in a class that extends photoview.
The problem is this resource is not being displayed, i also tried to use on a drawcirlce example that also didnt display. I have also attached that below.
@Override
protected void onDraw(Canvas canvas) {
super.onDraw(canvas);
Bitmap markerBitmap = BitmapFactory.decodeResource(activity.getResources(), R.drawable.markerformap);
canvas.drawBitmap(markerBitmap, 2000, 5000, new Paint());
}
Draw circle example
canvas.drawCircle(2000, 5000,300, new Paint());
The onTouch Listener
@Override
public boolean onTouch(View v, MotionEvent event) {
if(y != event.getY() && x != event.getX()){
x = event.getX();
y = event.getY();
return true;
}
return false;
}