473,748 Members | 9,599 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how to find polygon extreme points

19 New Member
hi, i need help to find extreme points of polygon. example triangle points. there is 3 extreme points on triangle, on each corner of the triangle structure example points A (8, 15), point B (1, 2) points C (16,2)does anyone can help me on it? the sample set size is 16X 16.

thanks
Mar 15 '10 #1
12 4659
ThatThatGuy
449 Recognized Expert Contributor
When you draw the polygon... you'll already have the points to be drawn for the polygon.... so whats the big deal
Mar 15 '10 #2
aznimah
19 New Member
@ThatThatGuy
i want to run a program to identify the extreme points since i took sketches from children. they size or area of drawn shape is varies from the individual...
Mar 15 '10 #3
GaryTexmo
1,501 Recognized Expert Top Contributor
Look into something called Convex Hull Generation (ie, Google). There's quite a few resources available for you, and the algorithm is pretty easy to code.

Here's some wiki pages, but you might want to google for more details :)

http://en.wikipedia.org/wiki/Convex_hull
http://en.wikipedia.org/wiki/Gift_wrapping_algorithm
Mar 15 '10 #4
RedSon
5,000 Recognized Expert Expert
Woah, that made me smarter!

Thanks Gary, I spent about two hours on wikipedia after that one.
Mar 15 '10 #5
GaryTexmo
1,501 Recognized Expert Top Contributor
Haha, glad you enjoyed it :)
Mar 15 '10 #6
aznimah
19 New Member
thanks Gary for the link ;D
Mar 24 '10 #7
aznimah
19 New Member
@GaryTexmo
hi Gary, i do really search for the convex hull as you suggest before. i have found some sources using C#. however, i did not know how to run the sources, could you help me?

i review the code from this link: http://www.discussweb.com/c-programm...n-drawing.html
i really appreciate if you could teach me how to run and see the output. thank you so much

i'm using Visual studio express edition 2008, Visual c#
Mar 30 '10 #8
GaryTexmo
1,501 Recognized Expert Top Contributor
Can you please tell me what you're stuck with? I don't really know what problem you're having... are you unable to get the code to compile? Is it crashing? Etc...
Mar 30 '10 #9
aznimah
19 New Member
@GaryTexmo
i unable to get the code to compile. i read tutorial, i just run the hello world. however when i look at the sources, contains two forms, and i did now how to execute it. or run it,
Mar 30 '10 #10

Sign in to post your reply or Sign up for a free account.

Similar topics

2
3160
by: Shamli | last post by:
I am looking for an algorithm that enlarge a 2D polygon. cheers,
6
4674
by: Adam Clauss | last post by:
I have a list of points (their coming in as decimal types, I can convert to PointF) that I am trying to draw to a form. Unfortunately, the coordinate system these points are coming from is not like Windows Forms use. Instead of (0,0) being the top left, (0,0) is in the "standard" graph position in the center of the coordinate plane. (So we have positive and negative values on both the x- and y- axis). Is there a "good" way to convert...
1
3193
by: G. Daniel via DotNetMonster.com | last post by:
can anybody help me?? using the mouse i let the user to draw a shape about a set of points, i want to define the points enclosed within this shape, the shape is irregular, i have saved all the points of that shape (which are defined by the mousedown event), the shape is not completely continous (due to moving the mouse very fast) but it is closed. if any body have any idea even if it is not completly correct, please support it, it may...
1
1167
by: Jaime | last post by:
When I send a graph (polygon) to printer, I receive the next message: Object referente not set to an instante of an object.--- at System.Drawing.SafeNativeMethods.GdipFillPolygonI(HandleRef graphics, HandleRef brush, HandleRef points, Int32 count, Int32 brushMode) at System.Drawing.Graphics.FillPolygon(Brush brush, Point points, FillMode fillMode) at WinAppSeguimiento.frmImpresion.PaintRadar(Graphics& graphToRender, Double paramRadio,...
6
3647
BSOB
by: BSOB | last post by:
im gone for a long weekend so plenty of time for anyone to answer. if i have 4 points representing a polygon and each point is represented by an x and a y coordinate, is there an easy (or slightly less painfull) way to decide whether or not a point (a,b) lays within that polygon? please note that this polygon DOES NOT take the shape of a square and has NO right angles and all side lengths are somewhat random. the application: say i...
1
8433
by: renu | last post by:
Hello, I have drawn polygon on window. And I want to check wheather given point is in that polygon region or not? How shold I find that? I have created object of class region GraphicsPath path = new GraphicsPath(); path.AddPolygon(pts); //////// Some points I have passed Region rgn = new Region(path); RegionData rgnDta = rgn.GetRegionData();
1
4505
by: jojojjose | last post by:
function draw() { var s=''; s+='<v:polygon points="'; s+= //points from server s+="> </v:polygon>'"; document.wrie(s); }
3
6157
by: jojo41300000 | last post by:
Hi, Is anyone know that how to get the x and y points inside the polygon using C++ program? I have the given polygon data to draw the polygon, but i don't know how to get all the points inside the polygon. Eg. Let's say we have 5 points to draw a polygon. Polygon ---------------------
41
3991
AccessIdiot
by: AccessIdiot | last post by:
I have a puzzle for all you sql fans. Imagine a polygon with 12 sides (SideA, SideB, SideC, etc) Within this polygon are 96 points (Pt1, Pt2, Pt3, etc). Now let's say I have a table that has the distances from each point to each side Point Side Distance Pt1 SideA 25.6683 Pt1 SideB 37.6778
8
2979
by: jpatchak | last post by:
Hello, I am having a problem using intersects method of a class I made that extends Polygon. Basically, I am trying to write code that allows the user to drag these polygons. I create a 1x1 rectangle on a mouse press and look through an array to see if the rectangle intersects the polygon. If it does, then I call the polygon's move class, passing the x and y coordinates while the user is dragging. Problem is that it works the first time,...
0
8991
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8830
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9541
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9370
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
9321
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9247
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6796
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6074
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4874
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.