B4A Library ABExtDrawing 1.0

Discussion in 'Additional libraries, classes and official updates' started by alwaysbusy, Feb 3, 2012.

  1. hookshy

    hookshy Well-Known Member Licensed User

    mask bitmap

    I searched for mask options and I did not found any.
    Is there a solution to mask a bitmap ?
  2. francoisg

    francoisg Active Member Licensed User

    Drop shadows

    is there any easy way of generating drop shadows? I have many images (transparent .png images) that I need to dynamically generate shadows for (images are loaded from a server and can change in the future, so using something like Photoshop to change the images would not work!) ...

    Any help would be appreciated!
  3. MrKim

    MrKim Well-Known Member Licensed User

    When I try to run ABMeter.b4a it loads a blank screen. The following is the log when it loads.

    Starting activity: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] flg=0x10200000 cmp=com.ab.abmeter/.main }
    Start proc com.ab.abmeter for activity com.ab.abmeter/.main: pid=472 uid=10039 gids={}
    Could not find method android.graphics.Canvas.isHardwareAccelerated, referenced from method com.AB.ABExtDrawing.ABExtDrawing.isHardwareAccelerated
    VFY: unable to resolve virtual method 226: Landroid/graphics/Canvas;.isHardwareAccelerated ()Z
    VFY: replacing opcode 0x6e at 0x0002
    VFY: dead code 0x0005-0006 in Lcom/AB/ABExtDrawing/ABExtDrawing;.isHardwareAccelerated (Lanywheresoftware/b4a/objects/drawable/CanvasWrapper;)Z
    ** Activity (main) Create, isFirst = true **
    GC_EXTERNAL_ALLOC freed 4766 objects / 259256 bytes in 88ms
    GC_EXTERNAL_ALLOC freed 817 objects / 42144 bytes in 78ms
    ** Activity (main) Resume **
    fdhandler_accept_event: accepting on fd 10
    created client 0x17fe8 listening on fd 15
    client_fd_receive: attempting registration for service 'sensors'
    client_fd_receive: -> received channel id 27
    Launch timeout has expired, giving up wake lock!
    Activity idle timeout for HistoryRecord{4500ac28 com.ab.abmeter/.main}
    request time failed: java.net.SocketException: Address family not supported by protocol

    I am using an Android 2.2 emulator API Level 8
    I get the same results with Google APIs 2.2 API Level 8

    I then have to force the App closed.
  4. NeoTechni

    NeoTechni Well-Known Member Licensed User

    I'm using mMatrix.setPolyToPoly and ExDraw.drawBitmap4 to draw part of a bitmap as a trapezoid using a SRC rect. The problem is, it's drawing the entire bitmap around that SRC instead of just what's inside it. How do I change that?

    I'm working around it with a path, but I'd prefer not to since you can only use 1 at a time.
  5. LucaMs

    LucaMs Expert Licensed User

    It is possible, using your ABExtDrawing and ABCamera, to get a picture (rear camera)
    and find an "object" (little bitmap) that is located in the picture obtained?
  6. alwaysbusy

    alwaysbusy Expert Licensed User

    @LucaMs No. ABCamera has nothing to do with the physical device camera. It is a 'viewpoint' camera that affect the draw functions on a canvas.
  7. LucaMs

    LucaMs Expert Licensed User

    Many thanks for your reply (especially because you are... alwaysbusy :))
    alwaysbusy likes this.
  8. klaus

    klaus Expert Licensed User

    You aked me here to look at this subject.
    Unfortunately I have no experience in this area.
    LucaMs likes this.
  9. LucaMs

    LucaMs Expert Licensed User

    Really "Unfortunately".

    But I'm sure that if you wanted ... and if I explained to you the purpose...!

    If you want, contact me "in private"
  10. danijel

    danijel Active Member Licensed User

    Can someone help me just draw picture on Canvas using this library?
    I need to avoid canvas using Nearest neighbor and I need to use Bicubic resample image.
    I trying without success.

    Basicly i need only this but with Bicubic resample image:
    Sub Globals
    Dim Canvas1 As Canvas
    Dim Logo As Bitmap
    End Sub

    Sub Activity_Create(FirstTime As Boolean)
    Dim SrcRect As Rect
    Dim DestRect As Rect
    End Sub
    I will be very grateful
    Last edited: May 29, 2014
  11. GMan

    GMan Well-Known Member Licensed User

    Where i can find the 3D Camera Project thread ?
    I want to add an background image behind the turning 3d "cubes"
  12. GMan

    GMan Well-Known Member Licensed User

    And how can i get/identify a clicked "cube" ?
  13. salim safran

    salim safran Member Licensed User

  14. HugoSX2

    HugoSX2 Member Licensed User

  15. alwaysbusy

    alwaysbusy Expert Licensed User

    There is an issue with drawtext on a canvas in Android 4.2.1. (maybe others). Google says you need to add the following to your paint:


    Then the text will show up ok.
  16. asales

    asales Well-Known Member Licensed User

    Great library!
    It's possible to lock the scrolling when the picture reaches the bottom?

    Attached Files:

  17. HugoSX2

    HugoSX2 Member Licensed User


    Thank you very much! ScalePaint.setLinearText(True) fixes the my problem. Great!
  18. ibra939

    ibra939 Active Member Licensed User

    thank you
  19. HugoSX2

    HugoSX2 Member Licensed User

  20. alwaysbusy

    alwaysbusy Expert Licensed User

    @HugoSX2 What do you mean a solution for 5? Does it give an error? I don't have a device with 5 yet.
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice