When I set the background to my surface view, I see what I set as the background. However, I cannot draw simple things like circles when I lock / unlock the canvas. All I see is a background image.
Is there something I am missing?
Any thoughts?
You missed google.
http://android-er.blogspot.com/2010/05/android-surfaceview.html
http://www.droidnova.com/playing-with-graphics-in-android-part-v,188.html
The solution is very simple.
//get surface view and surface holder mySurfaceView = (SurfaceView) findViewById(R.id.surfaceView); surfaceHolder = mySurfaceView.getHolder(); //place surface view holder on top of the surface view mySurfaceView.setZOrderOnTop(true); //set pixels of the surface holder to transparent to see the color of the //surface view background surfaceHolder.setFormat(PixelFormat.TRANSPARENT);
Source: https://habr.com/ru/post/1760808/More articles:fields_for, formtastic, ActiveMerchant and validation errors - ruby | fooobar.comPHP Fatal error caused by Magento - phpString double quotes are replaced by empty in C # - stringDetecting spiders or browsers with cookies enabled - phpMoving Postgres table spaces and tables through an EC2 instance - postgresqlC # Text Analysis - c #Delphi EStackoverflow exception troubleshooting tips - stack-overflowItem Width in ItemsControl - c #ASP.NET MVC Routing and File Path - .netLightSwitch Beta 1 searches for SQL Express instead of a full instance of SQL - sql-serverAll Articles