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 180169
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T14:32:19+00:00 2026-05-11T14:32:19+00:00

Starting from a totally empty MXML application: <?xml version=1.0 encoding=utf-8?> <mx:Application xmlns:mx=http://www.adobe.com/2006/mxml layout=absolute >

  • 0

Starting from a totally empty MXML application:

<?xml version='1.0' encoding='utf-8'?> <mx:Application xmlns:mx='http://www.adobe.com/2006/mxml'      layout='absolute' >  </mx:Application> 

What is the script that will:

  • create a bitmap (should this be a BitmapData object?)
  • programatically populate it with data (e.g. draw a circle) (is there any more efficient way to do this than repeatedly calling BitmapData.SetPixel?)
  • render it within the application (e.g. centered in the middle) (how DO I get a bitmap onto the screen? Online Flash samples show calling myBitmap=new Bitmap(myBitmapData) and then myBitmap.AddChild, but this throws an error in Flex).

??

NOTE: The goal is not just to get a circle on the screen, it’s to populate a Bitmap (or BitmapData? Or ???) object using SetPixel (or ???) and then get its contents onto the screen, as one would need to do in an image processing or visual effects application.

  • 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. 2026-05-11T14:32:19+00:00Added an answer on May 11, 2026 at 2:32 pm

    You have a couple of options. The first is to examine the Degrafa framework which has some really incredible drawing tools, otherwise you need to add a script block and use the AS3 drawing api in a function (in this case probably called on creationComplete:

    private function handleCreationComplete():void {     var component:UIComponent = new UIComponent(); //needed to add to the flex display list     var myCircle:Sprite = new Sprite();     myCircle.graphics.beginFill(0xFFFFFF,1)     myCircle.graphics.drawCircle(100,100,50);     component.addChild(myCircle);     this.addChild(component); } 

    This won’t center the circle, but you can figure that bit out.

    you can use this function to actually get the bitmap out of the above UIComponent:

    private function getBitmapData( target : UIComponent ) : BitmapData    {     var bd : BitmapData = new BitmapData( target.width, target.height );     var m : Matrix = new Matrix();     bd.draw( target, m );     return bd;    } 

    from here.

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

Sidebar

Ask A Question

Stats

  • Questions 117k
  • Answers 117k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer A PowerShell cmdlet is a compiled piece of .NET code,… May 11, 2026 at 10:48 pm
  • Editorial Team
    Editorial Team added an answer If you have the game state in an object (e.g.… May 11, 2026 at 10:48 pm
  • Editorial Team
    Editorial Team added an answer You can check the interface but not the attribute: public… May 11, 2026 at 10:48 pm

Related Questions

I have a homework assignment to write a multi-threaded sudoku solver, which finds all
I'm relatively new in the Java world and I have a problem which I
Our win32 applications (written in C++) have been around for over 10 years, and
We have an internal Flex application which has been designed more through feature creep

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.