Getting Polygon out of the Area

Hi,
I have an Area and after some transformation I am trying to get the Polygon out of it.
Does anyone know the best way to do it? Here is my code snippet:
int[] tPointsX= {0, 0, 100};
int[] tPointsY= {0, 50, 50};
int tN= 3;
Polygon triangle = new Polygon (tPointsX, tPointsY, tN );
int[] sPointsX= {0, 100, 0, 100};
int[] sPointsY= {0 ,0, 50, 50};
int sN= 4;
Polygon square= new Polygon (sPointsX, sPointsY, sN );
Area a1 = new Area (triangle);
Area a2 = new Area (square);
a2.subtract (a1);
Polygon finalResult = a2. ...? // how to get the polygon from the a2 after it
// has been transformed
Thanks for any hints
-Tom

Area class implements Shape interface, so you really don't need a method like area.getShape()

Similar Messages

  • I bought the Adobe Photoshop Classroom in a Book for CS6 by accident and I have CC. I know, stupid mistake. But I can't take return the book. Is is similar enough to CC that I can still get use out of the book? Thank you so much

    I bought the Adobe Photoshop Classroom in a Book for CS6 by accident and I have CC. I know, stupid mistake. But I can't take return the book. Is is similar enough to CC that I can still get use out of the book? Thank you so much

    Each version of Adobe products builds upon the previous ones.  Some things like filters and advanced features may evolve or become deprecated over time, but the basic tools have remained pretty much the same for decades.  As long as you know there are subtle differences between versions, I think you will still get a great deal of value from C in a B for CS6.  
    Also refer to the CC online tuts
    Photoshop CC tutorials | Learn how to use Photoshop CC
    Learn Photoshop CC | Adobe TV
    Nancy O.

  • I have taken all measures to clear my iPad but still getting kicked out of the internet and sent to my home page. What next?

    I have taken all recommended measures to clear my iPad Air but, I still get kicked out of the internet. Problem seems to be more frequent as time passes

    I don't know what you mean by "all recommended measures."
    Please tell me that it has NEVER been jailbroke.  If that's the case, here are some standard repair procedures:
    First, try a system reset.  It cures many ills and it's quick, easy and harmless...
    Hold down the on/off switch and the Home button simultaneously until you see the Apple logo.  Ignore the "Slide to power off" text if it appears.  You will not lose any apps, data, music, movies, settings, etc.
    If the Reset doesn't work, try a Restore.  Note that it's nowhere near as quick as a Reset.  It could take well over an hour!  Connect via cable to the computer that you use for sync.  From iTunes, select the iPad/iPod and then select the Summary tab.  Follow the on-screen directions for Restore and be sure to say "yes" to the backup.  You will be warned that all data (apps, music, movies, etc.) will be erased but, as the Restore finishes, you will be asked if you wish the contents of the backup to be copied to the iPad/iPod.  Again, say "yes."
    At the end of the basic Restore, you will be asked if you wish to sync the iPad/iPod.  As before, say "yes."  Note that that sync selection will disappear and the Restore will end if you do not respond within a reasonable time.  If that happens, only the apps that are part of the IOS will appear on your device.  Corrective action is simple -  choose manual "Sync" from the bottom right of iTunes.
    If you're unable to do the Restore (or it doesn't help), go into Recovery Mode per the instructions here.  You WILL lose all of your data (game scores, etc,) but, for the most part, you can redownload apps and music without being charged again.  Also, if you have IOS-7, read this.

  • I just purchased Photoshop 11.  The serial number is not valid to get me out of the trial.

    I just purchased Photoshop 11.  The serial number is not valid to get me out of the trial.

    You need to contact Adobe Support either by chat or via phone when you have serial number and activation issues.
    Here are some links to help make contact:
    http://www.adobe.com/support/chat/ivrchat.html
    http://www.adobe.com/support/download-install/supportinfo/

  • I have been trying to work on my homework all afternoon, via NAU's blackboard system. I am continuously getting booted out of the system, with an error stating "Data execution prevention". How can I prevent this from continuing?

    I have been trying to work on my homework all afternoon, via NAU's blackboard system. I am continuously getting booted out of the system, with an error stating "Data execution prevention". How can I prevent this from continuing?

    If you are wondering why you are not getting any responses, it is because you have vented a complaint without any details that make any sense or give anyone something to work on.
    If you want help, I suggest actually detailing what has happened, with versions of software etc. Anything that would let us assist.
    As a start I am guessing that you have not really got the hang of "How it all works". Firstly download the Pages09_UserGuide.pdf from under the Help menu. Read that and view the Video Tutorials in the same place. A good addition would be the iWork 09 Missing manual book and something to help you learn how to use your Mac.
    If there are specific tasks you need help with:
    http://www.freeforum101.com/iworktipsntrick/index.php?mforum=iworktipsntrick
    Is a good resource.
    Peter

  • How do you get mail out of the Outbox?

    How do you get mail out of the Outbox?  I've taken pictures and am trying to email them.  The emails are stuck in Outbox.
    lee.ann3

    Thanks Diggie, your response was very close.  I clicked on the email several times.  It came up and gave me the option to Send.  I clicked Send and my recipients received the email.
    I did not have to delete and reinstall my email account.
    Have a good day.
    lee.ann3

  • What if you are on contract & move out of the area or even out of the country for a time?

    I'm just wondering. My win mob 6.5 phone is not working very well. It freezes, the alarms have 5 alarms when only 1 was set & sometimes they seem to not even go off. Previously they would go off even when turned off--didn't seem to make a difference.  Sometimes it is really slow to open an email, etc. & this one was a replacement for the Touch Pro 2 which wasn't working right.
    So at any rate, I need to get a new one before long & want another smart phone--a reliable one this time. I would like to get the iPhone 4S I think.
    I'm eligible for an upgrade, although when I used the upgrade fundtion & looked at the iPhone 4S, it just showed the 2 yr price--it didn't show my New Every 2 discount.
    In addition, I'm not sure what  my long term plans are.  I'm not planning on moving anywhere real soon, but it is possible that I might be moving out of the area before 2 years are up or maybe not. Or I might even go overseas for awhile.
    So what happens if you are on a 2 year contract & move out of the area either permanently or out of the country for months or more? btw, before these smart phone fiascos, I kept my last previous basic LG flip phone for about 5 years because it just worked.

    So what if its a different Verizon region? You just move & keep your contract if there is service?
    & if you suspend without bllling, is there a time limit on that?
    Of course they should give you credit for months when you could get a new phone but keep the old one. Before this period just ending (which because they messed up & called a replacement an upgrade & put me on a new 2 yr contract when all along I said no, when I got that taken off & then corrected the upgrade date (originally it was supposed to be 12/2011 & they had changed it to 12/2012) rather than reset it back to the original they reset it to when I got the replacement phone or actually a few months later so I think the contract end date was in July. But now I wlll be up to when my original upgrade date should have been. Well actually I guess they allow you to upgrade maybe 22 mo or so into a contract or they used to.
    My previous phone before this 2 yr period I kept the phone for 5 years. The phone before that which was also a flip phone, the hinge broke at least a couple of mo before I was eligible for upgrade so I had it taped together.
    I didn't look at other phones & I don't know what their 2 yr contract price would be.

  • LabVIEW DSC: How to get alarm status from the area?

    Colleagues,
    I have, lets say, 50 Shared Variables where alarming enabled. Some of these variables assigned to area, so I can get status of the entire area or acknowledge an entire area of alarms (prior to version 8.x there was groups of the tags).
    Now I would like to get alarm status from the entire area. How can I do it?
    In version 6 I was able to wire tag group to Get Alarm Summary Status. Now, in version 8, Alarm Status.vi can be wired to the array of the variables, but not to area. Is it possible to get all variables from the area?
    regards,
    Andrey.

    I am not sure if I should be posting my problem under this particular topic. I am having trouble understanding acknowledge alarm vi and what this vi is supposed to do is not clear to me yet.
    I have around 300 shared variables in my project and I have created a particular vi just to view the alarms that may pop up during runs. I created a main menu and this alarm vi can be accessed upon a button click in the main menu. Users get alarm alert based on sound configuration. Then he can navigate to the alarm vi and acknowledge the alarm. The alarm vi only contains alarm and event display found under DSC module.
    The problem is everytime I click the alarm button in the main menu, it takes around 2 minutes for the alarm vi to update which is very annoying and unsatisfactory in the middle of run. I am not sure why it happens and I haven't got any response from support yet. These shared variables are managed under 10 different library files that are set up based on different loops of the process (flow, pressure and so on).
    Then I looked into three alarm examples that ship with DSC module. None of these examples use acknowledge alarm vi. I implemented another vi similar to alarm demo vi in that example - containing multicolumn listbox. I created acknowledge event containing acknowledge button and used the acknowledge alarm vi under this event. Read vi alarm is under timeout event.
    When I click the acknowledge button  as soon as I see the alarm in multicolumn listbox, nothing happens - the color of font does not get changed to purple neither any alarms get acknowledged. I tried to aknowledge alarm by variable name or  alarms or alarm area, it does not give me anything. What is this acknowledge alarm supposed to do? I tried to find examples everywhere in the web that uses this particular vi and haven't found one yet. 

  • HT4191 I have Notes that transferred to email when I set up a new email acct. They no longer appear in Notes. I can only access them in the email acct. How do I get them out of the email acct and back to the Notes app?

    I have Notes that transferred to an Email acct when I set up the acct. The Notes no longer appear in the Notes app only in the Email acct. How do I get them out of the Email acct and back to Notes? I stopped at an Apple store and they told me to copy them from the email back to Notes. But when I was in the email acct, I could not find a way to copy them. Shouldn't Notes remain in Notes unless I specifically send them somewhere else?

    Go into Settings > Mail, Contacts, Calendars, select that email account on the right-hand side of the screen and turn Notes 'on' for it - they should then appear in the Notes app instead of as an email folder in the Mail app (they will still be linked to that email account, so you may need to tap the 'Accounts' button at at the top left of the list of notes)

  • How do I store 4 hours of data and get it out of the "while loop" into a spreadshee​t file for documentin​g purposes? "See additional Text for additonal info"

    What a have is a VI that uses the following SUbvi's, starts with FP OpenVI, then FP Create TagVI, into a "While Loop" which contains a FP ReadVI outputting data into a Index ArrayVI outputting to a Display (DBL). This shows the output of a FP-AI-100 monitoring a 9v battery. I have to monitor this battery for a 4 hour period my problem is storing the 4 hours of data and getting it out of the "while loop" into a "Write to Spreadsheet File VI" all I seem to accomplish is just one data sample which I get into a spreed ship file with no problem. I just can't get 4 hours worth. By the way this is my first VI and I'm self
    trained so have mercy.

    I figured it out thanks.
    John Morris
    Glendinning Marine

  • How do I store 4 hours of data and get them out of the "while loop" into a spreadsheet file for documenting purposes? "See additional Text for additonal info"

    What a have is a VI that uses the following SUbvi's, starts with FP OPENvi, then FP Create Tagvi, into a "While Loop" which contains a FP READvi outputting data into a INDEX ARRAYvi outputting to a Display (DBL). This shows the output of a FP-AI-100 monitoring a 9v battery. I have to monitor this battery for a 4 hour period my problem is storing the 4 hours of data and getting it out of the "while loop" into a "Write to Spreadsheet File vi" all I seem to accomplish is just one data sample which I get into a spreed ship file with no problem. I just can't get 4 hours worth. By the way this is my first VI and I'm sel
    f trained so have mercy.

    I figured it out Thanks.
    John Morris
    Glendinning Marine

  • The icloud keeps asking for apple id but cannot get it out of the loop

    the icloud keeps asking for apple id but cannot get it out of the loop.  It will not let me delete or get to settings

    Perform a Reset... Try again...
    Reset  ( No Data will be Lost )
    Press and Hold the Sleep/Wake Button and the Home Button at the Same Time...
    Wait for the Apple logo to Appear...
    Usually takes about 15 - 20 Seconds... ( But can take Longer...)
    Release the Buttons...

  • Part of my headphones plug broke off in the port. how do i get it out? the genius bar said their tweezers would not fit

    part of my headphones plug broke off in the port. how do i get it out? the genius bar said their tweezers would not fit

    get smaller tweezers.  you need some type of small instrument.

  • HT203433 I am having trouble moving my music to my new computer. I have enable homeshare. it does not show any files in my homeshare. How do i get them out of the normal files into home share

    I am having trouble moving my music to my new computer. I have enable homeshare. it does not show any files in my homeshare. How do i get them out of the normal files into home share

    Welcome to the Apple Community.
    The following article(s) may help you.
    Moving your iTunes library to a new computer

  • HT1414 Mine keeps on saying that the device could not be restored, "an unknown error has occurred (2001)"!! Guess it's stuck in that dreaded "iPhone Recovery Mode" loop. The question is, which way out??? How do I get it out of the recovery loop??

    Mine keeps on saying that the device could not be restored, "an unknown error has occurred (2001)"!! Guess it's stuck in that dreaded "iPhone Recovery Mode" loop. The question is, which way out??? How do I get it out of the recovery loop??

    A quick Google search for Error 2001 would indicate that this occurs when you have a jailbroken phone or were trying to downgrade iOS. Is that true for you?

Maybe you are looking for