#Region Project Attributes
#MainFormWidth: 1024
#MainFormHeight: 768
#End Region
Sub Process_Globals
Private MainForm As Form
Private fx As JFX
Private xui As XUI
Private imgAnatomie As B4XBitmap
Private AnatomieRect As B4XRect
Private sizeWidth As Double = 561
Private sizeHeight As Double = 522
Private Panel1 As B4XView
Private cvs As B4XCanvas
End Sub
Sub AppStart (Form1 As Form, Args() As String)
MainForm = Form1
MainForm.RootPane.LoadLayout("1")
MainForm.Show
Create
End Sub
Sub Create
Panel1.Width = sizeWidth
Panel1.Height = sizeHeight
imgAnatomie = xui.LoadBitmapResize(File.DirAssets, "Becken.jpg", sizeWidth, sizeHeight, False)
AnatomieRect.Initialize(0, 0, sizeWidth, sizeHeight)
cvs.Initialize(Panel1)
cvs.ClearRect(cvs.TargetRect)
cvs.DrawBitmap(imgAnatomie, AnatomieRect)
cvs.Invalidate
End Sub
Sub Panel1_MouseClicked (EventData As MouseEvent)
cvs.DrawCircle(EventData.X,EventData.Y,30,xui.Color_ARGB(150,255,255,255),True,1)
Dim i As Image = imgAnatomie
Dim out As OutputStream
out = File.OpenOutput(File.DirApp, "1.jpg", False)
i.WriteToStream(out)
out.Close
End Sub