Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8777501
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T19:17:34+00:00 2026-06-13T19:17:34+00:00

I’m creating a drawing app in Flash with AS3. The brushstroke is created with

  • 0

I’m creating a drawing app in Flash with AS3. The “brushstroke” is created with a bitmap. This code seems to work fine when the brushstrokes are spread out. [SEE IMAGE 1]

But when the same stroke is clicked repeatedly in the same spot, it’s evident the the brushstroke is not only adding alpha but deleting it as well. [SEE IMAGE 2] I want to eliminate the “box” shape surrounding the brushstroke.

The code snippet that I’m currently using is below. Is there such thing as an “alpha add” so that this alpha subtraction doesn’t occur? The brushstroke blob is here for reference. [SEE IMAGE 3]

1
Drawing app http://theluv.is/downloading/drawImg1.png
2
Drawing app http://theluv.is/downloading/drawImg2.png
3
Drawing app http://theluv.is/downloading/brushBlob.png

function stampImage(){
var matrix:Matrix = new Matrix();
matrix.translate(mouseX + brushOffsetX, mouseY + brushOffsetY);

maskSprite.graphics.beginBitmapFill(blob, matrix, false, false);
maskSprite.graphics.drawRect(mouseX + brushOffsetX, mouseY + brushOffsetY, blob.width, blob.height);
maskSprite.graphics.endFill();
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-13T19:17:34+00:00Added an answer on June 13, 2026 at 7:17 pm

    Use BitmapData.copyPixels method. You can specify alpha blending there.
    Of course you’ll have to modify your code. First of all you’ll have a canvas bitmapdata.

    var bmpd:BitmapData;
    

    And to draw it on screen you just create a Bitmap object.

    var bmp:Bitmap = new Bitmap(...);
    bmp.bitmapData = bmpd;
    addChild(bmp);
    

    When you want to draw something use

    bmpd.copyPixels(blob, blob.rect, new Point(x,y), null, null, true);
    

    Where blob is a BitmapData with your brush texture.

    The problem will be if you want to rotate brush texture. In this case use BitmapData.draw.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
this is what i have right now Drawing an RSS feed into the php,
I have this code to decode numeric html entities to the UTF8 equivalent character.
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString
link Im having trouble converting the html entites into html characters, (&# 8217;) i
For some reason, after submitting a string like this Jack’s Spindle from a text
We're building an app, our first using Rails 3, and we're having to build
This could be a duplicate question, but I have no idea what search terms
I know there's a lot of other questions out there that deal with this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.