For those who want to check it out with a reference to vbRichClient5 (offering antialiasing on the Clip-Regions,
and working on any Win-OS), here's replacement code for Form1 of dilettantes WIA-demo.
Producing this:Code:Option Explicit Private CC As cCairoContext Private Sub Form_Load() Cairo.ImageList.AddImage "BackDrop", LoadResData("BACKDROP", "PNG") Cairo.ImageList.AddImage "Curtain", LoadResData("CURTAIN", "PNG") ScaleMode = vbPixels Set CC = Cairo.CreateSurface(ScaleWidth, ScaleHeight).CreateContext Redraw Picture1.Visible = False '<- we don't need that End Sub Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single) Redraw X, Y, 100 End Sub Private Sub Redraw(Optional ByVal xc&, Optional ByVal yc&, Optional ByVal Radius&) CC.RenderSurfaceContent "Curtain", 0, 0 CC.ARC xc, yc, Radius CC.Clip CC.RenderSurfaceContent "BackDrop", 0, 0 CC.ResetClip Set Picture = CC.Surface.Picture End Sub Private Sub Form_Terminate() New_c.CleanupRichClientDll End Sub
Olaf





Reply With Quote
