Vector graphics: Difference between revisions
[pending revision] | [accepted revision] |
→Overview: mmkmhjohklojhoolkkjo,jk,ol,jp, 2 Tag: repeating characters |
|||
(995 intermediate revisions by more than 100 users not shown) | |||
Line 1: | Line 1: | ||
{{short description|Computer graphics images defined by points, lines and curves}} |
|||
{{this|computer illustration}} |
|||
{{about|computer illustration}} |
|||
{{Refimprove|date=January 2008}} |
|||
{{pp-pc|small=yes}} |
|||
[[Image:VectorBitmapExample.svg|thumb|220px|Example showing effect of vector graphics versus raster graphics. The original vector-based illustration is at the left. The upper-right image illustrates magnification of 7x as a vector image. The lower-right image illustrates the same magnification as a bitmap image. Raster images are based on pixels and thus scale with loss of clarity, while vector-based images can be scaled indefinitely without degrading quality.]] |
|||
{{Use mdy dates|date=July 2020}} |
|||
'''Vector graphics''' is the use of geometrical [[Primitive (geometry)|primitive]]s such as [[point (spatial)|point]]s, [[line (mathematics)|lines]], [[curve]]s, and shapes or [[polygon]](s), which are all based on mathematical equations, to represent [[image]]s in [[computer graphics]]. |
|||
[[File:Bitmap VS SVG.svg|thumb|upright=1.3|Example showing comparison of vector graphics and [[raster graphics]] upon [[magnification]]]] |
|||
Vector graphics formats are complementary to [[raster graphics]], which is the representation of images as an array of [[pixel]]s, as is typically used for the representation of photographic images.<ref>{{cite book | title = Processing: Creative Coding and Computational Art | author = Ira Greenberg | publisher = [[Apress]] | year = 2007 | isbn = 159059617X | url = http://books.google.com/books?id=WTl_7H5HUZAC&pg=PA115&dq=raster+vector+graphics+photographic&lr=&as_brr=0&ei=llOVR5LKCJL0iwGZ8-ywBw&sig=YEjfPOYSUDIf1CUbL5S5Jbzs7M8 }}</ref> There are instances when working with vector tools and formats is the best practice, and instances when working with raster tools and formats is the best practice. There are times when both formats come together. An understanding of the advantages and limitations of each technology and the relationship between them is most likely to result in efficient and effective use of tools. |
|||
'''Vector graphics''' are a form of [[computer graphics]] in which visual images are created directly from [[Geometric primitive|geometric shapes]] defined on a [[Cartesian coordinate system|Cartesian plane]], such as [[point (geometry)|points]], [[Line segment|lines]], [[curve]]s and [[polygon]]s. The associated mechanisms may include vector display and printing ''hardware'', vector ''data models'' and file formats, as well as the ''software'' based on these data models (especially [[Graphic art software|graphic design software]], [[computer-aided design]], and [[geographic information system]]s). Vector graphics are an alternative to [[Raster graphics|raster]] or bitmap graphics, with each having advantages and disadvantages in specific situations.<ref name="ChapmanChapman2002">{{cite book|author1=Nigel Chapman|author2=Jenny Chapman|title=Digital Multimedia|url=https://archive.org/details/digitalmultimedi00chap|url-access=limited|year=2002|orig-year=2000|publisher=Wiley|isbn=0-471-98386-1|page=[https://archive.org/details/digitalmultimedi00chap/page/n100 86]}}</ref> |
|||
== Overview == |
|||
Computer displays are made up from grids of small rectangular cells called [[pixels]]. The picture is built up from these cells. The smaller and closer the cells are together, the better the quality of the image, but the bigger the file needed to store the data. If the number of pixels is kept constant, the size of each pixel will grow and the image becomes grainy (pixellated) when magnified, as the resolution of the eye enables it to pick out individual pixels.Vector graphics files store the lines, shapes and colors that make up an image as mathematical formulae. A vector graphics program uses these mathematical formulae to construct the screen image, building the best quality image possible, given the screen resolution. The mathematical formulae determine where the dots that make up the image should be placed for the best results when displaying the image. Since these formulae can produce an image scalable to any size and detail, the quality of the image is limited only by the resolution of the display, and the file size of vector data generating the image stays the same. Printing the image to paper will usually give a sharper, higher resolution output than printing it to the screen but can use exactly the same vector dakkmkmjmkjm,nmkmlnlml |
|||
,mml,l,,kj,k,k,l,,kjlmjollomljlo kbhhkmhkmomkhmhkmbkmmknkmkknhmjho |
|||
h,nhmjmjkmlhjommkhjmjlnm[mmmnmkn,mkb,nbl,knhmmm |
|||
=== Editing vector graphics === |
|||
[[vector graphics editor|Vector graphic drawing software]] is used for creating and editing vector graphics. The image can be changed by editing screen objects which are then saved as modifications to the mathematical formulae. Mathematical operators in the software can be used to stretch, twist, and color component objects in the picture or the whole picture, and these tools are presented to the user intuitively through the graphical user interface of the computer. It is possible to save the screen image produced as a bitmap/raster file or generate a [[bitmap]] of any resolution from the vector file for use on any device. |
|||
While vector hardware has largely disappeared in favor of raster-based monitors and printers,<ref name="Kaufman1993">{{cite book|author=Arie Kaufman|title=Rendering, Visualization and Rasterization Hardware|url=https://books.google.com/books?id=lF4irp7bBN0C&pg=PA86|year=1993|publisher=Springer Science & Business Media|isbn=978-3-540-56787-5|pages=86–87}}</ref> vector data and software continue to be widely used, especially when a high degree of geometric precision is required, and when complex information can be decomposed into simple geometric primitives. Thus, it is the preferred model for domains such as [[engineering]], [[architecture]], [[surveying]], [[3D rendering]], and [[typography]], but is entirely inappropriate{{Citation needed|date=November 2024}} for applications such as [[photography]] and [[remote sensing]], where raster is more effective and efficient. Some application domains, such as geographic information systems (GIS) and [[graphic design]], use both vector and raster graphics at times, depending on purpose. |
|||
The size of the file generated will depend on the resolution required, but the size of the vector file generating the bitmap/raster file will always remain the same. Thus, it is easy to convert from a vector file to a range of bitmap/raster [[file formats]] but it is much more difficult to go in the opposite direction, especially if subsequent editing of the vector picture is required. It might be an advantage to save an image created from a vector source file as a bitmap/raster format, because different systems have different (and incompatible) vector formats, and some might not support vector graphics at all. However, once a file is converted from the vector format, it is likely to be bigger, and it loses the advantage of scalability without loss of resolution. It will also no longer be possible to edit individual parts of the image as discrete objects. The file sŪmmlnmlm,lm.nm;,mlm. ;m ;lmlm.ml ,gkmh,Vector formats are not always appropriate in graphics work. For example, devices such as cameras and scanners produce raster graphics that are impractical to convert into vectors, and so for this type of work, the editor will operate on the pixels rather than on drawing objects defined by mathematical formulae. Comprehensive graphics tools will combine images from vector and raster sources, and may provide editing tools for both, since some parts of an image could come from a camera source, and others could have been drawn using vector tools. |
|||
Vector graphics are based on the mathematics of [[Analytic geometry|analytic or coordinate geometry]], and is not related to other mathematical uses of the term [[Euclidean vector|vector]]. This can lead to some confusion in disciplines in which both meanings are used. |
|||
=== Standards === |
|||
The [[W3C]] standard for vector graphics is [[SVG]]. The standard is complex and has been relatively slow to be established at least in part owing to commercial interests. Many web browsers now have some support for rendering SVG data but full implementations of the standard are still comparatively rare. |
|||
==Data model== |
|||
[[File:Phone.jpg|thumb|180px|An original reference photograph before [[Raster to vector|vectorization]]]] |
|||
{{see also | Geometric primitive}} |
|||
[[File:Phone.svg|thumb|180px|Detail can be added or removed from vector art. Vector illustrations can have their own color, allowing artists to achieve desired results.]] |
|||
The [[Logical schema|logical data model]] of vector graphics is based on the mathematics of [[Analytic geometry|coordinate geometry]], in which shapes are defined as a set of points in a two- or three-dimensional [[cartesian coordinate system]], as ''p'' = (''x, y'') or ''p'' = (''x, y, z''). Because almost all shapes consist of an infinite number of points, the vector model defines a limited set of [[geometric primitive]]s that can be specified using a finite sample of salient points called [[Vertex (computer graphics)|vertices]]. For example, a square can be unambiguously defined by the locations of three of its four corners, from which the software can [[interpolation|interpolate]] the connecting boundary lines and the interior space. Because it is a regular shape, a square could also be defined by the location of one corner, a size (width=height), and a rotation angle. |
|||
The fundamental geometric primitives are: |
|||
=== Applications === |
|||
* A single [[Point (geometry)|point]]. |
|||
One of the first uses of vector graphic displays was the [[Semi Automatic Ground Environment|US SAGE air defense system]]. Vector graphics systems were only retired from U.S. en route [[air traffic control]] in 1999, and are likely still in use in military and specialised systems. Vector graphics were also used on the [[TX-2]] at the [[Massachusetts Institute of Technology|MIT]] [[Lincoln Laboratory]] by computer graphics pioneer [[Ivan Sutherland]] to run his program [[Sketchpad]] in 1963. |
|||
* A [[line segment]], defined by two end points, allowing for a simple [[linear interpolation]] of the intervening line. |
|||
* A [[polygonal chain]] or polyline, a connected set of line segments, defined by an ordered list of points. |
|||
* A [[polygon]], representing a region of space, defined by its boundary, a polyline with coincident starting and ending vertices. |
|||
A variety of more complex shapes may be supported: |
|||
Subsequent vector graphics systems, most of which iterated through dynamically modifiable stored lists of drawing instructions, include [[Digital Equipment Corporation|Digital]]'s GT40.<ref>{{cite web|url=http://www.brouhaha.com/~eric/retrocomputing/dec/gt40/|title="DEC GT40 Graphic Display Terminal"|accessdate=2009-05-06}}</ref> There was a home gaming system that used vector graphics called [[Vectrex]] as well as various [[arcade game]]s like ''[[Asteroids (computer game)|Asteroids]]'' and ''[[Space Wars]]''. Storage scope displays, such as the [[Tektronix 4014]], could display vector images but not modify them without first erasing the display. |
|||
* [[Parametric equation|Parametric curves]], in which polylines or polygons are augmented with parameters to define a non-linear interpolation between vertices, including [[circular arc]]s, [[Cubic Hermite spline|cubic splines]], [[Catmull–Rom spline]]s, [[Bézier curve]]s and [[bezigon]]s. |
|||
* Standard parametric shapes in two or three dimensions, such as [[circle]]s, [[ellipse]]s, [[square]]s, [[superellipse]]s, [[sphere]]s, [[tetrahedron]]s, [[superellipsoid]]s, etc. |
|||
* Irregular three-dimensional surfaces and solids, are usually defined as a connected set of polygons (e.g., a [[polygon mesh]]) or as parametric surfaces (e.g., [[NURBS]]). |
|||
* [[Fractal]]s, often defined as an [[iterated function system]]. |
|||
In many vector datasets, each shape can be combined with a set of properties. The most common are visual characteristics, such as color, line weight, or dash pattern. In systems in which shapes represent real-world features, such as GIS and BIM, a variety of attributes of each represented feature can be stored, such as name, age, size, and so on.<ref>[https://saylordotorg.github.io/text_essentials-of-geographic-information-systems/s08-02-vector-data-models.html Vector Data Models] {{Webarchive|url=https://web.archive.org/web/20220411030138/https://saylordotorg.github.io/text_essentials-of-geographic-information-systems/s08-02-vector-data-models.html |date=April 11, 2022 }}, ''Essentials of Geographic Information Systems'', Saylor Academy, 2012</ref> |
|||
Modern vector graphics displays can sometimes be found at [[Laser lighting display|laser light shows]], where two fast-moving X-Y [[mirror]]s are used to rapidly draw shapes and text on a screen. |
|||
In some Vector data, especially in GIS, information about [[Geospatial topology|topological relationships]] between objects may be represented in the data model, such as tracking the connections between road segments in a [[transport network]].<ref name="Bolstad">{{cite book |last1=Bolstad |first1=Paul |title=GIS Fundamentals: A First Text on Geographic Information Systems |date=2008 |publisher=Eider Press |page=37 |edition=3rd}}</ref> |
|||
The term "vector graphics" is mainly used today in the context of two-dimensional computer graphics. It is one of several modes an artist can use to create an image on a raster display. Other modes include text, [[multimedia]], and [[3D rendering]]. Virtually all modern 3D rendering is done using extensions of 2D vector graphics techniques. [[Plotter]]s used in technical drawing still draw vectors directly to paper. |
|||
If a dataset stored in one vector file format is converted to another file format that supports all the primitive objects used in that particular image, then the conversion can be lossless. |
|||
== Information == |
|||
For example, consider a [[circle]] of [[radius]] ''r''. The main pieces of [[information]] a [[computer program|program]] needs in order to draw this circle are |
|||
==Vector display hardware== |
|||
# an indication that what is to be drawn is a circle |
|||
{{main|Vector monitor}} |
|||
# the radius ''r'' |
|||
[[File:Space Rocks (game).jpg|thumb|A free software ''[[Asteroids (game)|Asteroids]]''-like video game played on a [[vector monitor]]]] |
|||
# the [[coordinate|location]] of the center point of the circle |
|||
Vector-based devices, such as the vector CRT and the [[Plotter|pen plotter]], directly control a drawing mechanism to produce geometric shapes. Since vector display devices can define a line by dealing with just two points (that is, the coordinates of each end of the line), the device can reduce the total amount of data it must deal with by organizing the image in terms of pairs of points.{{sfn|Murray|2002|pp=81–83}} |
|||
# stroke line style and color (possibly transparent) |
|||
# fill style and color (possibly transparent) |
|||
Vector graphic displays were first used in 1958 by the [[Semi Automatic Ground Environment|US SAGE air defense system]].<ref>{{cite thesis|url=https://aaltodoc.aalto.fi/bitstream/handle/123456789/38066/master_Holzer_Ian_2019.pdf|title=Vector Synthesis: a Media-Archaeological Investigation into Sound-Modulated Light|last=Holzer|first=Derek|publisher=[[Aalto University]]|date=April 2019|access-date=July 31, 2020|id={{URN|NBN|fi:aalto-201905193156}}|archive-date=April 18, 2021|archive-url=https://web.archive.org/web/20210418193445/https://aaltodoc.aalto.fi/bitstream/handle/123456789/38066/master_Holzer_Ian_2019.pdf|url-status=live}}</ref> Vector graphics systems were retired from the U.S. en route [[air traffic control]] in 1999.{{citation needed|date=July 2020}} Vector graphics were also used on the [[TX-2]] at the Massachusetts Institute of Technology [[Lincoln Laboratory]] by computer graphics pioneer [[Ivan Sutherland]] to run his program [[Sketchpad]] in 1963.<ref>{{cite thesis|url=http://hdl.handle.net/10919/63920|title=The Sketchpad Window|last=Kassem|first=Dalal|publisher=[[Virginia Polytechnic Institute and State University]]|date=October 15, 2014|access-date=September 18, 2020|hdl=10919/63920}}</ref> |
|||
Advantages to this style of [[drawing]] over [[raster graphics]]: |
|||
* This minimal amount of information translates to a much smaller [[file size]] compared to large raster images (the [[size]] of representation does not depend on the [[dimension]]s of the object), though a vector graphic with a small file size is often said to lack detail compared with a real world photo. |
|||
* Correspondingly, one can indefinitely zoom in on e.g. a circle arc, and it remains smooth. On the other hand, a polygon representing a curve will reveal being not really curved. |
|||
* On zooming in, lines and curves need not get wider proportionally. Often the width is either not increased or less than proportional. On the other hand, irregular curves represented by simple geometric shapes may be made proportionally wider when zooming in, to keep them looking smooth and not like these geometric shapes. |
|||
* The parameters of objects are stored and can be later modified. This means that [[motion (physics)|moving]], [[Image scaling|scaling]], [[rotating]], [[fill]]ing etc. doesn't degrade the quality of a drawing. Moreover, it is usual to specify the dimensions in device-independent units, which results in the best possible [[rasterization]] on raster [[peripheral device|device]]s. |
|||
* From a 3-D perspective, rendering shadows is also much more realistic with vector graphics, as shadows can be abstracted into the rays of light from which they are formed. This allows for photo realistic images and renderings. |
|||
Subsequent vector graphics systems, most of which iterated through dynamically modifiable stored lists of drawing instructions, include the [[IBM 2250]], [[Imlac PDS-1]], and [[DEC GT40]]. There was a video game console that used vector graphics called [[Vectrex]] as well as various [[arcade game]]s like ''[[Asteroids (video game)|Asteroids]]'', ''[[Space Wars]],'' [[Tempest (video game)|''Tempest'']] and many cinematronics titles such as ''[[Rip-Off|Rip Off]]'', and ''[[Tail Gunner]]'' using [[vector monitor]]s.<ref>{{cite book|url=https://books.google.com/books?id=XiM0ntMybNwC&pg=PA67|title=The Video Game Explosion: A History from PONG to Playstation and Beyond|last=Wolf|first=Mark J. P.|publisher=[[ABC-CLIO]]|date=2008|access-date=July 31, 2020|pages=67–71|isbn=978-0-313-33868-7}}</ref> Storage scope displays, such as the [[Tektronix 4014]], could display vector images but not modify them without first erasing the display. However, these were never as widely used as the raster-based scanning displays used for television, and had largely disappeared by the mid-1980s except for specialized applications. |
|||
== Typical primitive objects == |
|||
* [[Bézier curve]]s |
|||
* [[Bezigon]]s |
|||
* [[Circle]]s and [[ellipse]]s |
|||
* Lines and [[polyline]]s |
|||
* [[Polygon]]s |
|||
* [[Character (computing)|Text]] (in computer font formats such as [[TrueType]] where each letter is created from [[Bézier curve]]s) |
|||
[[Plotter]]s used in [[technical drawing]] still draw vectors directly to paper by moving a pen as directed through the two-dimensional space of the paper. However, as with monitors, these have largely been replaced by the [[wide-format printer]] that prints a raster image (which may be rendered from vector data). |
|||
This list is not complete. There are various types of curves ([[Catmull-Rom spline]]s, [[NURBS]] etc.), which are useful in certain applications. |
|||
==Software== |
|||
Often, a [[Raster graphics|bitmap]] image is considered as a primitive object. From the conceptual view, it behaves as a [[rectangle]]. |
|||
Because this model is useful in a variety of application domains, many different software programs have been created for drawing, manipulating, and visualizing vector graphics. While these are all based on the same basic vector data model, they can interpret and structure shapes very differently, using very different file formats. |
|||
* Graphic design and illustration, using a [[vector graphics editor]] or [[graphic art software]] such as [[Adobe Illustrator]]. See [[Comparison of vector graphics editors]] for capabilities. |
|||
* [[Geographic information system]]s (GIS), which can represent a geographic feature by a combination of a vector shape and a set of attributes.<ref name="Peuquet">Peuquet, Donna J. (1984), "[https://www.researchgate.net/publication/244954245_A_Conceptual_Framework_and_Comparison_of_Spatial_Data_Models A Conceptual Framework and Comparison of Spatial Data Models]", ''Cartographica'' 21 (4): 66–113. {{doi|10.3138/D794-N214-221R-23R5}}. {{Webarchive|url=https://web.archive.org/web/20211024054823/https://www.researchgate.net/publication/244954245_A_Conceptual_Framework_and_Comparison_of_Spatial_Data_Models |date=October 24, 2021 }}.</ref> GIS includes vector editing, mapping, and vector [[spatial analysis]] capabilities. |
|||
* [[Computer-aided design]] (CAD), used in engineering, architecture, and surveying. [[Building information modeling]] (BIM) models add attributes to each shape, similar to a GIS. |
|||
* [[3D computer graphics]] software, including [[computer animation]]. |
|||
== File formats ==<!-- image floats with header --> |
|||
== Vector operations == |
|||
<!-- keep together -->[[File:Vector-based example.svg|thumb|This vector-based (SVG format) image of a round four-color swirl displays several unique features of vector graphics versus raster graphics: there is no [[aliasing]] along the rounded edge (which would result in [[digital artifacts]] in a raster graphic), the [[color gradient]]s are all smooth, and the user can resize the image infinitely without losing any quality.]] |
|||
[[Vector graphics editor]]s typically allow rotation, movement, mirroring, stretching, skewing, [[affine transformation]]s, changing of [[z-order]] and combination of primitives into more complex objects. |
|||
Vector graphics are commonly found today in the [[Scalable vector graphics|SVG]], [[Windows Metafile|WMF]], [[Encapsulated PostScript|EPS]], [[PDF]], [[CorelDraw|CDR]] or [[Adobe Illustrator Artwork|AI]] types of [[Image file formats|graphic file formats]], and are intrinsically different from the more common raster graphics file formats such as [[JPEG]], [[Portable Network Graphics|PNG]], [[APNG]], [[GIF]], [[WebP]], [[BMP File Format|BMP]] and [[MPEG4]]. |
|||
The [[World Wide Web Consortium]] (W3C) standard for vector graphics is [[Scalable Vector Graphics]] (SVG). The standard is complex and has been relatively slow to be established at least in part owing to commercial interests. Many web browsers now have some support for rendering SVG data but full implementations of the standard are still comparatively rare. |
|||
More sophisticated [[transformation (mathematics)|transformation]]s include set [[Operation (mathematics)|operations]] on closed [[shape]]s ([[union (set theory)|union]], [[complement (set theory)|difference]], [[intersection (set theory)|intersection]], etc.). |
|||
In recent years, SVG has become a significant format that is completely independent of the resolution of the rendering device, typically a [[Printer (computing)|printer]] or display monitor. SVG files are essentially printable text that describes both straight and curved paths, as well as other attributes. Wikipedia prefers SVG for images such as simple maps, line illustrations, coats of arms, and flags, which generally are not like photographs or other continuous-tone images.{{cn|date=November 2023}} Rendering SVG requires conversion to a raster format at a resolution appropriate for the current task. SVG is also a format for animated graphics. |
|||
Vector graphics are ideal for simple or composite drawings that need to be device-independent, or do not need to achieve [[photo-realism]]. For example, the [[PostScript]] and [[Portable Document Format|PDF]] [[page description language]]s use a vector graphics model. |
|||
There is also a version of SVG for mobile phones. In particular, the specific format for mobile phones is called SVGT (SVG Tiny version). These images can count links and also exploit anti-aliasing. They can also be displayed as wallpaper. |
|||
== Printing == |
|||
Vector art is key for [[printing]]. Since the art is made from a series of mathematical curves it will print very crisply even when resized. For instance, one can print a vector logo on a small sheet of copy paper, and then enlarge the same vector logo to [[Billboard (advertising)|billboard]] size and keep the same crisp quality. A low-resolution [[raster graphic]] would blur or pixelate excessively if it were enlarged from business card size to billboard size. (The precise resolution of a raster graphic necessary for high-quality results depends on the viewing distance; e.g., a billboard may still appear to be of high quality even at low resolution if the viewing distance is large enough.) |
|||
CAD software uses its own vector data formats, usually proprietary formats created by software vendors, such as [[Autodesk]]'s [[DWG]] and public exchange formats such as [[DXF]]. Hundreds of distinct [[GIS file formats|vector file formats]] have been created for GIS data over its history, including proprietary formats like the [[Esri file geodatabase]], proprietary but public formats like the [[Shapefile]] and the original [[KML]], open source formats like [[GeoJSON]], and formats created by standards bodies like [[Simple Features]] and [[Geography Markup Language|GML]] from the [[Open Geospatial Consortium]]. |
|||
If we regard typographic characters as images, then the same considerations that we have made for graphics apply even to composition of written text for printing ([[typesetting]]). Older character sets were stored as bitmaps, therefore to achieve maximum print quality they had to be used at a given resolution only; these font formats are said to be non-scalable. High quality typography is nowadays based on character drawings ([[font]]s) which are typically stored as vector graphics, and as such are scalable to any size. Examples of these vector formats for characters are [[Postscript fonts]] and [[TrueType fonts]]. |
|||
== |
=== Conversion === |
||
{{Hatnote|The list of [[image file format]]s covers proprietary and public [[Image file formats#Vector formats|vector formats]].}} |
|||
Vector illustration is a popular technique of many digital illustrators worldwide. Some of the greatest internationally acclaimed artists in the field are [[Catalina Estrada]], [[Petra Stefankova]], [[Nathan Jurevicius]], [[J. Otto Seibold]], Leo Blanchette and others. |
|||
[[File:Phone.jpg|thumb|Original reference photo before [[Raster to vector|vectorization]]]] |
|||
[[File:Phone.svg|thumb|Detail can be added to or removed from vector art.]] |
|||
== |
====To raster==== |
||
{{main article|Rasterisation|Raster image processor|Render output unit}} |
|||
{{Main|3D modelling}} |
|||
In [[3D computer graphics]], vectorized surface representations are most common (bitmaps can be used for special purposes such as surface texturing, height-field data and [[bump mapping]]). At the low-end, simple [[polygon mesh|meshes]] of [[polygon]]s are used to represent geometric detail in applications where interactive [[frame rate]]s or [[simplicity]] are important. At the high-end, where one is willing to trade-off higher rendering times for increased image quality and [[precision]], smooth [[surface]] representations such as [[Bézier surface|Bézier patch]]es, [[NURBS]] or [[Subdivision surface]]s are used. One can, however, achieve a smooth surface rendering from a polygonal mesh through the use of shading algorithms such as [[Phong shading|Phong]] and [[Gouraud shading|Gouraud]]. |
|||
Modern displays and printers are [[raster graphics|raster]] devices; vector formats have to be converted to a raster format (bitmaps – pixel arrays) before they can be rendered (displayed or printed).{{Sfn|Gharachorloo|Gupta|Sproull|Sutherland|1989|p=355}} The size of the bitmap/raster-format file generated by the conversion will depend on the resolution required, but the size of the vector file generating the bitmap/raster file will always remain the same. Thus, it is easy to convert from a vector file to a range of bitmap/raster [[file formats]] but it is much more difficult to go in the opposite direction, especially if subsequent editing of the vector picture is required. It might be an advantage to save an image created from a vector source file as a bitmap/raster format, because different systems have different (and incompatible) vector formats, and some might not support vector graphics at all. However, once a file is converted from the vector format, it is likely to be bigger, and it loses the advantage of scalability without loss of resolution. It will also no longer be possible to edit individual parts of the image as discrete objects. The file size of a vector graphic image depends on the number of graphic elements it contains; it is a list of descriptions. |
|||
== Formats == |
|||
{{Main|Image file formats#Vector formats|l1=Vector formats}} |
|||
One example of vector graphics format is [[Scalable Vector Graphics|SVG]] (Scalable Vector Graphics), an [[open standard]] created and developed by the [[World Wide Web Consortium]] to address the need (and attempts of several corporations) for a versatile, [[DOM scripting|scriptable]] and all-purpose vector format for the web and otherwise. Another example is [[VML]], a proposed standard that was adopted by [[Microsoft]]. Arguably, the AI format, the native format for [[Adobe Illustrator]], is also standard in vector graphics. |
|||
====From raster==== |
|||
The [[SWF]] Adobe's (formerly Macromedia's) file format is also a vector based container used to store animation. Web pages created in Flash can be enlarged to fit any monitor size while retaining the same graphic quality. |
|||
{{main article|Vectorization (image tracing)|Comparison of raster-to-vector conversion software}} |
|||
{{empty section|date=June 2018}} |
|||
=== Printing === |
|||
[[Adobe Fireworks]], which is also (mostly) a vector-based application, saves its files in [[Portable Network Graphics|PNG]] format; vectors created in Adobe Fireworks can be transferred to Adobe Illustrator, and vice versa. |
|||
Vector art is ideal for [[printing]] since the art is made from a series of mathematical curves; it will print very crisply even when resized.<ref>{{cite web |url=http://www.olypress.com/vector-vs-raster-graphics-in-printing/ |title=Vector & Raster Graphics in Offset Printing |date=December 6, 2013 |publisher=Olympus Press |access-date=2014-06-16 |archive-date=February 12, 2014 |archive-url=https://web.archive.org/web/20140212111440/http://www.olypress.com/vector-vs-raster-graphics-in-printing/ |url-status=live }}</ref> For instance, one can print a vector logo on a small sheet of copy paper, and then enlarge the same vector logo to [[Billboard (advertising)|billboard]] size and keep the same crisp quality. A low-resolution [[raster graphic]] would blur or pixelate excessively if it were enlarged from business card size to billboard size. (The precise resolution of a raster graphic necessary for high-quality results depends on the viewing distance; e.g., a billboard may still appear to be of high quality even at low resolution if the viewing distance is great enough.)<ref>{{cite web |url=http://unix.eng.ua.edu/MathWorks/manuals/techdoc/creating_plots/chprin30.html |archive-url=https://archive.today/20140206130749/http://unix.eng.ua.edu/MathWorks/manuals/techdoc/creating_plots/chprin30.html |url-status=dead |archive-date=February 6, 2014 |title=Printing and Exporting (Graphics) |publisher=COE Unix Network |date=2002-06-18 |access-date=2014-06-16 }}</ref> |
|||
If we regard typographic characters as images, then the same considerations that we have made for graphics apply even to the composition of written text for printing ([[typesetting]]). Older character sets were stored as bitmaps. Therefore, to achieve maximum print quality they had to be used at a given resolution only; these font formats are said to be non-scalable. High-quality typography is nowadays based on character drawings ([[font]]s) which are typically stored as vector graphics, and as such are scalable to any size. Examples of these vector formats for characters are [[Postscript fonts]] and [[TrueType fonts]]. |
|||
== Operation == |
|||
Advantages of this style of [[drawing]] over [[raster graphics]]: |
|||
* Because vector graphics consist of coordinates with lines/curves between them, the size of the representation does not depend on the [[dimension]]s of the object. This minimal amount of information translates to a much smaller<ref>{{Cite web |title=PNG vs. SVG: What are the differences? |url=https://www.adobe.com/creativecloud/file-types/image/comparison/png-vs-svg |access-date=2023-12-12 |website=Adobe }}</ref> [[file size]] compared to large raster images which are defined pixel by pixel. This said, a vector graphic with a small file size is often said to lack detail compared with a real-world photo. |
|||
* Correspondingly, one can infinitely zoom in on e.g., a circle arc, and it remains smooth. On the other hand, a polygon representing a curve will reveal being not really curved. |
|||
* On zooming in, lines and curves need not get wider proportionally. Often the width is either not increased or less than proportional. On the other hand, irregular curves represented by simple geometric shapes may be made proportionally wider when zooming in, to keep them looking smooth and not like these geometric shapes. |
|||
* The parameters of objects are stored and can be later modified. This means that [[motion (physics)|moving]], [[Image scaling|scaling]], [[rotating]], [[Flood fill|fill]]ing, etc. does not degrade the quality of a drawing. Moreover, it is usual to specify the dimensions in device-independent units, which results in the best possible [[rasterization]] on raster [[peripheral device|device]]s. |
|||
* From a 3-D perspective, rendering shadows is also much more realistic with vector graphics, as shadows can be abstracted into the rays of light from which they are formed. This allows for [[photorealistic]] images and [[Rendering (computer graphics)|renderings]]. |
|||
For example, consider a [[circle]] of [[radius]] ''r''.<ref>{{cite web |url=http://www1.chapman.edu/~jipsen/asciisvg.html |title=ASCIIsvg: Easy mathematical vector graphics |publisher=Peter Jipsen, Chapman University |access-date=2014-06-16 |archive-date=September 16, 2013 |archive-url=https://web.archive.org/web/20130916181927/http://www1.chapman.edu/~jipsen/asciisvg.html |url-status=live }}</ref> The main pieces of [[information]] a [[computer program|program]] needs in order to draw this circle are |
|||
# An indication that what is to be drawn is a circle |
|||
# the radius ''r'' |
|||
# the [[coordinate|location]] of the center point of the circle |
|||
# stroke line style and color (possibly transparent) |
|||
# fill style and color (possibly transparent) |
|||
Vector formats are not always appropriate in graphics work and also have numerous disadvantages.<ref>{{cite web |author=Andy Harris |url=http://wally.cs.iupui.edu/n351/vector/Vector_Graphics.html |title=Vector Graphics |website=Welcome to wally!!! |access-date=2014-06-16 |url-status=dead |archive-url=https://web.archive.org/web/20120518050735/http://wally.cs.iupui.edu/n351/vector/Vector_Graphics.html |archive-date=2012-05-18}}</ref> For example, devices such as cameras and scanners produce essentially continuous-tone [[raster graphics]] that are impractical to convert into vectors, and so for this type of work, an image editor will operate on the pixels rather than on drawing objects defined by mathematical expressions. Comprehensive graphics tools will combine [[image]]s from vector and raster sources, and may provide editing tools for both, since some parts of an image could come from a camera source, and others could have been drawn using vector tools. |
|||
Some authors have criticized the term ''vector graphics'' as being confusing.<ref name="ChapmanChapman2002b"/><ref>[http://www.slideshare.net/Mark_Kilgard/22pathrender, CS 354 Vector Graphics & Path Rendering] {{Webarchive|url=https://web.archive.org/web/20200418024910/http://www.slideshare.net/Mark_Kilgard/22pathrender, |date=April 18, 2020 }}, Slide 7, By Mark Kilgard, April 10, 2012, University of Texas at Austin</ref> In particular, ''vector graphics'' does not simply refer to graphics described by [[Euclidean vector]]s.<ref name="Spuy2010">{{cite book|author=Rex van der Spuy |title=AdvancED Game Design with Flash|url=https://books.google.com/books?id=Xsheyw3JJrMC&pg=PA306|year=2010|publisher=Apress|isbn=978-1-4302-2739-7|page=306}}</ref> Some authors have proposed to use ''object-oriented graphics'' instead.<ref name="ChapmanChapman2002b"/><ref name="Landau2000">{{cite book|author=Ted Landau|title=Sad Macs, Bombs and Other Disasters |url=https://archive.org/details/mac_Sad_Macs_Bombs_and_other_Disasters_4th_Edition_2000 |year=2000|publisher=Peachpit Press|isbn=978-0-201-69963-0|edition=4th |page=[https://archive.org/details/mac_Sad_Macs_Bombs_and_other_Disasters_4th_Edition_2000/page/n421 409]}}</ref><ref name="Arntson2011">{{cite book|author=Amy Arntson|title=Graphic Design Basics |url=https://books.google.com/books?id=LSM9AAAAQBAJ&pg=PA194|year=2011|publisher=Cengage Learning |isbn=978-1-133-41950-1|page=194|edition=6th}}</ref> However this term can also be confusing as it can be read as any kind of graphics implemented using [[object-oriented programming]].<ref name="ChapmanChapman2002b">{{cite book|author1=Nigel Chapman|author2=Jenny Chapman|year=2002|orig-year=2000|title=Digital Multimedia |url=https://archive.org/details/digitalmultimedi00chap|url-access=limited|publisher=Wiley |isbn=0-471-98386-1|page=[https://archive.org/details/digitalmultimedi00chap/page/n84 70]}}</ref> |
|||
== Vector operations == |
|||
[[Vector graphics editor]]s typically allow translation, rotation, mirroring, stretching, skewing, [[affine transformation]]s, changing of [[z-order]] (loosely, what's in front of what) and combination of primitives into more complex objects.<ref name="ChapmanChapman2002b" /> More sophisticated [[transformation (mathematics)|transformation]]s include [[Set (mathematics)#Basic operations|set operations]] on closed [[shape]]s ([[union (set theory)|union]], [[complement (set theory)|difference]], [[intersection (set theory)|intersection]], etc.).{{Sfn|Barr|1984|p=21}} In SVG, the composition operations are based on [[alpha composition]].<ref>{{cite web|title=SVG Compositing Specification|author=SVG Working Group|website=w3|url=https://www.w3.org/TR/SVGCompositing|date=15 March 2011|access-date=8 August 2022|archive-date=August 7, 2022|archive-url=https://web.archive.org/web/20220807173633/https://www.w3.org/TR/SVGCompositing/|url-status=live}}</ref> |
|||
Vector graphics are ideal for simple or composite drawings that need to be device-independent,<ref>{{cite thesis |last=Qin |first=Zheng |date=January 27, 2009 |title=Vector Graphics for Real-time 3D Rendering |publisher=[[University of Waterloo]] |page=1 |url=https://uwspace.uwaterloo.ca/bitstream/handle/10012/4262/phd-thesis.pdf |access-date=July 28, 2020 |hdl=10012/4262 |archive-date=July 28, 2020 |archive-url=https://web.archive.org/web/20200728125357/https://uwspace.uwaterloo.ca/bitstream/handle/10012/4262/phd-thesis.pdf |url-status=live }}</ref> or do not need to achieve [[photo-realism]]. For example, the [[PostScript]] and [[PDF]] [[page description language]]s use a vector graphics model. |
|||
== Vector image repositories == |
|||
Many stock photo websites provide vectorized versions of hosted images, while specific repositories specialize in vector images given their growing popularity among graphic designers.<ref>{{Cite web |date=April 2023 |title=Stock Photos Websites Market Report {{!}} Global Forecast From 2023 To 2032 |url=https://datasetsearch.research.google.com/search?src=0&query=vector%20images&docid=L2cvMTF5NjVrMnhicg== |access-date=2024-08-25 |website=datasetsearch.research.google.com}}</ref> |
|||
{| class="wikitable" |
|||
! colspan="2" |List of vector image repositories<ref>{{Cite web |last=Says |first=Studyessay org |date=2022-03-21 |title=7 of the Best Vector Sites for Graphic Designers |url=https://blog.spoongraphics.co.uk/articles/7-of-the-best-vector-sites-for-graphic-designers |access-date=2024-08-25 |website=Spoon Graphics |language=en-US}}</ref> |
|||
|- |
|||
!Repo/Company |
|||
!License |
|||
|- |
|||
|[[Vexels (website)|Vexels]] |
|||
!{{Nonfree|Proprietary}} |
|||
|- |
|||
|[[VectorStock]] |
|||
!{{Nonfree|Proprietary}} |
|||
|- |
|||
|[[Vecteezy]] |
|||
!{{Free|Freemium}} |
|||
|- |
|||
|[[Freepik]] |
|||
!{{Nonfree|Proprietary}} |
|||
|- |
|||
|[[Evanto Elements]] |
|||
!{{Nonfree|Proprietary}} |
|||
|- |
|||
|[[Depositphotos]] |
|||
!{{Nonfree|Proprietary}} |
|||
|} |
|||
== See also == |
== See also == |
||
{{div col |colwidth=22em}} |
|||
{{wikiversity|Vector Drawing}} |
|||
* [[Animation]] |
|||
{{div col | cols=3}} |
|||
* [[Adobe Fireworks]] |
|||
* [[Adobe Illustrator]] |
|||
* [[Anti-Grain Geometry]] |
* [[Anti-Grain Geometry]] |
||
* [[Cairo (graphics)]] |
* [[Cairo (graphics)]] |
||
* [[Comparison of vector graphics editors]] |
|||
* [[Cardboard engineering]] |
|||
* [[Comparison of graphics file formats]] |
|||
* [[Computer-aided design]] |
* [[Computer-aided design]] |
||
* [[ |
* [[Direct2D]] |
||
* [[Illustration]] |
|||
* [[Map#Electronic maps|Electronic maps]] |
|||
* [[Javascript graphics library]] |
|||
* [[Graphics file format summary]] |
|||
* [[Graphics software]] |
|||
* [[GTX Image Cad Software]] |
|||
* [[GXL]] (Graph eXchange Language) |
|||
* [[Inkscape]] |
|||
* [[List of vector graphics editors]] |
|||
* [[List of vector graphics markup languages]] |
|||
* [[Raster to vector]] |
* [[Raster to vector]] |
||
* [[Raster graphics]] |
|||
* [[Scalable Vector Graphics]] (SVG) |
|||
* [[ |
* [[Resolution independence]] |
||
* [[Turtle graphics]] |
* [[Turtle graphics]] |
||
* [[Vector game]] |
* [[Vector game]] |
||
* [[Vector graphics |
* [[Vector graphics file formats]] |
||
* [[Vector Markup Language]] (VML) |
|||
* [[Vector monitor]] |
* [[Vector monitor]] |
||
* [[Vector network]] |
|||
* [[Vector packs]] |
|||
* [[Vexel]] |
* [[Vexel]] |
||
* [[VRML]] |
|||
* [[Wire frame model]] |
* [[Wire frame model]] |
||
* [[3D modeling]] |
|||
{{div col end}} |
{{div col end}} |
||
== |
== Notes == |
||
{{Reflist}} |
{{Reflist}} |
||
== References == |
|||
{{DEFAULTSORT:Vector Graphics}} |
|||
* {{cite book|last=Barr|first=Alan H.|title=Proceedings of the 11th annual conference on Computer graphics and interactive techniques |chapter=Global and local deformations of solid primitives |chapter-url=http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.67.6046&rep=rep1&type=pdf|chapter-format=PDF|date=July 1984 |access-date=July 31, 2020|volume=18|issue=3|pages = 21–30|doi=10.1145/800031.808573|isbn = 0897911385|citeseerx = 10.1.1.67.6046|s2cid = 16162806}} |
|||
* {{cite book|last1=Gharachorloo|first1=Nader|last2=Gupta|first2=Satish|author-link3=Bob Sproull|last3=Sproull|first3=Robert F.|author-link4=Ivan Sutherland|last4=Sutherland|first4=Ivan E. |title=Proceedings of the 16th annual conference on Computer graphics and interactive techniques |chapter=A characterization of ten rasterization techniques |chapter-url=http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.105.461&type=pdf|chapter-format=PDF|date=July 1989 |access-date=July 28, 2020|volume=23|issue=3|pages = 355–368|doi=10.1145/74333.74370|isbn = 0201504340|citeseerx = 10.1.1.105.461|s2cid = 8253227}} |
|||
* {{cite book |last=Murray |first=Stephen |year=2002 |chapter=Graphic Devices |editor=Roger R. Flynn |title=Computer Sciences, Vol 2: Software and Hardware, Macmillan Reference USA |publisher=Gale eBooks |url=https://link-gale-com.libaccess.lib.mcmaster.ca/apps/doc/CX3401200218/GVRL?u=ocul_mcmaster&sid=GVRL&xid=acaf5d43 |url-access=limited |access-date=3 Aug 2020}} |
|||
== External links == |
|||
{{wikiversity|Vector Drawing}} |
|||
* {{Commons category-inline|Vector graphics}} |
|||
{{Graphics file formats}} |
|||
{{Authority control}} |
|||
{{DEFAULTSORT:Vector graphics}} |
|||
[[Category:Vector graphics| ]] |
[[Category:Vector graphics| ]] |
||
[[Category:Graphic design]] |
[[Category:Graphic design]] |
||
[[Category:Graphics file formats]] |
|||
[[Category:Design]] |
|||
[[ar:رسوميات متجهية]] |
|||
[[bn:ভেক্টর গ্রাফিক্স]] |
|||
[[be:Вектарная графіка]] |
|||
[[bs:Vektorska grafika]] |
|||
[[bg:Векторна графика]] |
|||
[[ca:Gràfic vectorial]] |
|||
[[cs:Vektorová grafika]] |
|||
[[da:Vektorgrafik]] |
|||
[[de:Vektorgrafik]] |
|||
[[et:Vektorgraafika]] |
|||
[[es:Gráfico vectorial]] |
|||
[[eo:Vektora bildo]] |
|||
[[eu:Grafiko bektorial]] |
|||
[[fa:گرافیک برداری]] |
|||
[[fr:Image vectorielle]] |
|||
[[ko:벡터 그래픽스]] |
|||
[[id:Gambar vektor]] |
|||
[[is:Vigurmynd]] |
|||
[[it:Grafica vettoriale]] |
|||
[[he:גרפיקה וקטורית]] |
|||
[[ka:ვექტორული გამოსახულება]] |
|||
[[lv:Vektorgrafika]] |
|||
[[hu:Vektorgrafika]] |
|||
[[mk:Векторска графика]] |
|||
[[ms:Grafik vektor]] |
|||
[[nl:Vectorafbeelding]] |
|||
[[ja:ベクターイメージ]] |
|||
[[no:Vektorgrafikk]] |
|||
[[pl:Grafika wektorowa]] |
|||
[[pt:Desenho vetorial]] |
|||
[[ro:Grafică vectorială]] |
|||
[[ru:Векторная графика]] |
|||
[[simple:Vector graphics]] |
|||
[[sk:Vektorová grafika]] |
|||
[[sl:Vektorska grafika]] |
|||
[[sr:Векторска графика]] |
|||
[[sh:Vektorska grafika]] |
|||
[[fi:Vektorigrafiikka]] |
|||
[[sv:Vektorgrafik]] |
|||
[[ta:திசையன் வரைகலை]] |
|||
[[th:ภาพกราฟิกส์เวกเตอร์]] |
|||
[[uk:Векторна графіка]] |
|||
[[ur:سمتی تخطیط]] |
|||
[[zh:矢量图形]] |
Latest revision as of 15:07, 2 December 2024
Vector graphics are a form of computer graphics in which visual images are created directly from geometric shapes defined on a Cartesian plane, such as points, lines, curves and polygons. The associated mechanisms may include vector display and printing hardware, vector data models and file formats, as well as the software based on these data models (especially graphic design software, computer-aided design, and geographic information systems). Vector graphics are an alternative to raster or bitmap graphics, with each having advantages and disadvantages in specific situations.[1]
While vector hardware has largely disappeared in favor of raster-based monitors and printers,[2] vector data and software continue to be widely used, especially when a high degree of geometric precision is required, and when complex information can be decomposed into simple geometric primitives. Thus, it is the preferred model for domains such as engineering, architecture, surveying, 3D rendering, and typography, but is entirely inappropriate[citation needed] for applications such as photography and remote sensing, where raster is more effective and efficient. Some application domains, such as geographic information systems (GIS) and graphic design, use both vector and raster graphics at times, depending on purpose.
Vector graphics are based on the mathematics of analytic or coordinate geometry, and is not related to other mathematical uses of the term vector. This can lead to some confusion in disciplines in which both meanings are used.
Data model
[edit]The logical data model of vector graphics is based on the mathematics of coordinate geometry, in which shapes are defined as a set of points in a two- or three-dimensional cartesian coordinate system, as p = (x, y) or p = (x, y, z). Because almost all shapes consist of an infinite number of points, the vector model defines a limited set of geometric primitives that can be specified using a finite sample of salient points called vertices. For example, a square can be unambiguously defined by the locations of three of its four corners, from which the software can interpolate the connecting boundary lines and the interior space. Because it is a regular shape, a square could also be defined by the location of one corner, a size (width=height), and a rotation angle.
The fundamental geometric primitives are:
- A single point.
- A line segment, defined by two end points, allowing for a simple linear interpolation of the intervening line.
- A polygonal chain or polyline, a connected set of line segments, defined by an ordered list of points.
- A polygon, representing a region of space, defined by its boundary, a polyline with coincident starting and ending vertices.
A variety of more complex shapes may be supported:
- Parametric curves, in which polylines or polygons are augmented with parameters to define a non-linear interpolation between vertices, including circular arcs, cubic splines, Catmull–Rom splines, Bézier curves and bezigons.
- Standard parametric shapes in two or three dimensions, such as circles, ellipses, squares, superellipses, spheres, tetrahedrons, superellipsoids, etc.
- Irregular three-dimensional surfaces and solids, are usually defined as a connected set of polygons (e.g., a polygon mesh) or as parametric surfaces (e.g., NURBS).
- Fractals, often defined as an iterated function system.
In many vector datasets, each shape can be combined with a set of properties. The most common are visual characteristics, such as color, line weight, or dash pattern. In systems in which shapes represent real-world features, such as GIS and BIM, a variety of attributes of each represented feature can be stored, such as name, age, size, and so on.[3]
In some Vector data, especially in GIS, information about topological relationships between objects may be represented in the data model, such as tracking the connections between road segments in a transport network.[4]
If a dataset stored in one vector file format is converted to another file format that supports all the primitive objects used in that particular image, then the conversion can be lossless.
Vector display hardware
[edit]Vector-based devices, such as the vector CRT and the pen plotter, directly control a drawing mechanism to produce geometric shapes. Since vector display devices can define a line by dealing with just two points (that is, the coordinates of each end of the line), the device can reduce the total amount of data it must deal with by organizing the image in terms of pairs of points.[5]
Vector graphic displays were first used in 1958 by the US SAGE air defense system.[6] Vector graphics systems were retired from the U.S. en route air traffic control in 1999.[citation needed] Vector graphics were also used on the TX-2 at the Massachusetts Institute of Technology Lincoln Laboratory by computer graphics pioneer Ivan Sutherland to run his program Sketchpad in 1963.[7]
Subsequent vector graphics systems, most of which iterated through dynamically modifiable stored lists of drawing instructions, include the IBM 2250, Imlac PDS-1, and DEC GT40. There was a video game console that used vector graphics called Vectrex as well as various arcade games like Asteroids, Space Wars, Tempest and many cinematronics titles such as Rip Off, and Tail Gunner using vector monitors.[8] Storage scope displays, such as the Tektronix 4014, could display vector images but not modify them without first erasing the display. However, these were never as widely used as the raster-based scanning displays used for television, and had largely disappeared by the mid-1980s except for specialized applications.
Plotters used in technical drawing still draw vectors directly to paper by moving a pen as directed through the two-dimensional space of the paper. However, as with monitors, these have largely been replaced by the wide-format printer that prints a raster image (which may be rendered from vector data).
Software
[edit]Because this model is useful in a variety of application domains, many different software programs have been created for drawing, manipulating, and visualizing vector graphics. While these are all based on the same basic vector data model, they can interpret and structure shapes very differently, using very different file formats.
- Graphic design and illustration, using a vector graphics editor or graphic art software such as Adobe Illustrator. See Comparison of vector graphics editors for capabilities.
- Geographic information systems (GIS), which can represent a geographic feature by a combination of a vector shape and a set of attributes.[9] GIS includes vector editing, mapping, and vector spatial analysis capabilities.
- Computer-aided design (CAD), used in engineering, architecture, and surveying. Building information modeling (BIM) models add attributes to each shape, similar to a GIS.
- 3D computer graphics software, including computer animation.
File formats
[edit]Vector graphics are commonly found today in the SVG, WMF, EPS, PDF, CDR or AI types of graphic file formats, and are intrinsically different from the more common raster graphics file formats such as JPEG, PNG, APNG, GIF, WebP, BMP and MPEG4.
The World Wide Web Consortium (W3C) standard for vector graphics is Scalable Vector Graphics (SVG). The standard is complex and has been relatively slow to be established at least in part owing to commercial interests. Many web browsers now have some support for rendering SVG data but full implementations of the standard are still comparatively rare.
In recent years, SVG has become a significant format that is completely independent of the resolution of the rendering device, typically a printer or display monitor. SVG files are essentially printable text that describes both straight and curved paths, as well as other attributes. Wikipedia prefers SVG for images such as simple maps, line illustrations, coats of arms, and flags, which generally are not like photographs or other continuous-tone images.[citation needed] Rendering SVG requires conversion to a raster format at a resolution appropriate for the current task. SVG is also a format for animated graphics.
There is also a version of SVG for mobile phones. In particular, the specific format for mobile phones is called SVGT (SVG Tiny version). These images can count links and also exploit anti-aliasing. They can also be displayed as wallpaper.
CAD software uses its own vector data formats, usually proprietary formats created by software vendors, such as Autodesk's DWG and public exchange formats such as DXF. Hundreds of distinct vector file formats have been created for GIS data over its history, including proprietary formats like the Esri file geodatabase, proprietary but public formats like the Shapefile and the original KML, open source formats like GeoJSON, and formats created by standards bodies like Simple Features and GML from the Open Geospatial Consortium.
Conversion
[edit]To raster
[edit]Modern displays and printers are raster devices; vector formats have to be converted to a raster format (bitmaps – pixel arrays) before they can be rendered (displayed or printed).[10] The size of the bitmap/raster-format file generated by the conversion will depend on the resolution required, but the size of the vector file generating the bitmap/raster file will always remain the same. Thus, it is easy to convert from a vector file to a range of bitmap/raster file formats but it is much more difficult to go in the opposite direction, especially if subsequent editing of the vector picture is required. It might be an advantage to save an image created from a vector source file as a bitmap/raster format, because different systems have different (and incompatible) vector formats, and some might not support vector graphics at all. However, once a file is converted from the vector format, it is likely to be bigger, and it loses the advantage of scalability without loss of resolution. It will also no longer be possible to edit individual parts of the image as discrete objects. The file size of a vector graphic image depends on the number of graphic elements it contains; it is a list of descriptions.
From raster
[edit]This section is empty. You can help by adding to it. (June 2018) |
Printing
[edit]Vector art is ideal for printing since the art is made from a series of mathematical curves; it will print very crisply even when resized.[11] For instance, one can print a vector logo on a small sheet of copy paper, and then enlarge the same vector logo to billboard size and keep the same crisp quality. A low-resolution raster graphic would blur or pixelate excessively if it were enlarged from business card size to billboard size. (The precise resolution of a raster graphic necessary for high-quality results depends on the viewing distance; e.g., a billboard may still appear to be of high quality even at low resolution if the viewing distance is great enough.)[12]
If we regard typographic characters as images, then the same considerations that we have made for graphics apply even to the composition of written text for printing (typesetting). Older character sets were stored as bitmaps. Therefore, to achieve maximum print quality they had to be used at a given resolution only; these font formats are said to be non-scalable. High-quality typography is nowadays based on character drawings (fonts) which are typically stored as vector graphics, and as such are scalable to any size. Examples of these vector formats for characters are Postscript fonts and TrueType fonts.
Operation
[edit]Advantages of this style of drawing over raster graphics:
- Because vector graphics consist of coordinates with lines/curves between them, the size of the representation does not depend on the dimensions of the object. This minimal amount of information translates to a much smaller[13] file size compared to large raster images which are defined pixel by pixel. This said, a vector graphic with a small file size is often said to lack detail compared with a real-world photo.
- Correspondingly, one can infinitely zoom in on e.g., a circle arc, and it remains smooth. On the other hand, a polygon representing a curve will reveal being not really curved.
- On zooming in, lines and curves need not get wider proportionally. Often the width is either not increased or less than proportional. On the other hand, irregular curves represented by simple geometric shapes may be made proportionally wider when zooming in, to keep them looking smooth and not like these geometric shapes.
- The parameters of objects are stored and can be later modified. This means that moving, scaling, rotating, filling, etc. does not degrade the quality of a drawing. Moreover, it is usual to specify the dimensions in device-independent units, which results in the best possible rasterization on raster devices.
- From a 3-D perspective, rendering shadows is also much more realistic with vector graphics, as shadows can be abstracted into the rays of light from which they are formed. This allows for photorealistic images and renderings.
For example, consider a circle of radius r.[14] The main pieces of information a program needs in order to draw this circle are
- An indication that what is to be drawn is a circle
- the radius r
- the location of the center point of the circle
- stroke line style and color (possibly transparent)
- fill style and color (possibly transparent)
Vector formats are not always appropriate in graphics work and also have numerous disadvantages.[15] For example, devices such as cameras and scanners produce essentially continuous-tone raster graphics that are impractical to convert into vectors, and so for this type of work, an image editor will operate on the pixels rather than on drawing objects defined by mathematical expressions. Comprehensive graphics tools will combine images from vector and raster sources, and may provide editing tools for both, since some parts of an image could come from a camera source, and others could have been drawn using vector tools.
Some authors have criticized the term vector graphics as being confusing.[16][17] In particular, vector graphics does not simply refer to graphics described by Euclidean vectors.[18] Some authors have proposed to use object-oriented graphics instead.[16][19][20] However this term can also be confusing as it can be read as any kind of graphics implemented using object-oriented programming.[16]
Vector operations
[edit]Vector graphics editors typically allow translation, rotation, mirroring, stretching, skewing, affine transformations, changing of z-order (loosely, what's in front of what) and combination of primitives into more complex objects.[16] More sophisticated transformations include set operations on closed shapes (union, difference, intersection, etc.).[21] In SVG, the composition operations are based on alpha composition.[22]
Vector graphics are ideal for simple or composite drawings that need to be device-independent,[23] or do not need to achieve photo-realism. For example, the PostScript and PDF page description languages use a vector graphics model.
Vector image repositories
[edit]Many stock photo websites provide vectorized versions of hosted images, while specific repositories specialize in vector images given their growing popularity among graphic designers.[24]
List of vector image repositories[25] | |
---|---|
Repo/Company | License |
Vexels | Proprietary |
VectorStock | Proprietary |
Vecteezy | Freemium |
Freepik | Proprietary |
Evanto Elements | Proprietary |
Depositphotos | Proprietary |
See also
[edit]- Animation
- Anti-Grain Geometry
- Cairo (graphics)
- Comparison of vector graphics editors
- Comparison of graphics file formats
- Computer-aided design
- Direct2D
- Illustration
- Javascript graphics library
- Raster to vector
- Raster graphics
- Resolution independence
- Turtle graphics
- Vector game
- Vector graphics file formats
- Vector monitor
- Vector network
- Vector packs
- Vexel
- Wire frame model
- 3D modeling
Notes
[edit]- ^ Nigel Chapman; Jenny Chapman (2002) [2000]. Digital Multimedia. Wiley. p. 86. ISBN 0-471-98386-1.
- ^ Arie Kaufman (1993). Rendering, Visualization and Rasterization Hardware. Springer Science & Business Media. pp. 86–87. ISBN 978-3-540-56787-5.
- ^ Vector Data Models Archived April 11, 2022, at the Wayback Machine, Essentials of Geographic Information Systems, Saylor Academy, 2012
- ^ Bolstad, Paul (2008). GIS Fundamentals: A First Text on Geographic Information Systems (3rd ed.). Eider Press. p. 37.
- ^ Murray 2002, pp. 81–83.
- ^ Holzer, Derek (April 2019). Vector Synthesis: a Media-Archaeological Investigation into Sound-Modulated Light (PDF) (Thesis). Aalto University. urn:urn:NBN:fi:aalto-201905193156. Archived (PDF) from the original on April 18, 2021. Retrieved July 31, 2020.
- ^ Kassem, Dalal (October 15, 2014). The Sketchpad Window (Thesis). Virginia Polytechnic Institute and State University. hdl:10919/63920. Retrieved September 18, 2020.
- ^ Wolf, Mark J. P. (2008). The Video Game Explosion: A History from PONG to Playstation and Beyond. ABC-CLIO. pp. 67–71. ISBN 978-0-313-33868-7. Retrieved July 31, 2020.
- ^ Peuquet, Donna J. (1984), "A Conceptual Framework and Comparison of Spatial Data Models", Cartographica 21 (4): 66–113. doi:10.3138/D794-N214-221R-23R5. Archived October 24, 2021, at the Wayback Machine.
- ^ Gharachorloo et al. 1989, p. 355.
- ^ "Vector & Raster Graphics in Offset Printing". Olympus Press. December 6, 2013. Archived from the original on February 12, 2014. Retrieved June 16, 2014.
- ^ "Printing and Exporting (Graphics)". COE Unix Network. June 18, 2002. Archived from the original on February 6, 2014. Retrieved June 16, 2014.
- ^ "PNG vs. SVG: What are the differences?". Adobe. Retrieved December 12, 2023.
- ^ "ASCIIsvg: Easy mathematical vector graphics". Peter Jipsen, Chapman University. Archived from the original on September 16, 2013. Retrieved June 16, 2014.
- ^ Andy Harris. "Vector Graphics". Welcome to wally!!!. Archived from the original on May 18, 2012. Retrieved June 16, 2014.
- ^ a b c d Nigel Chapman; Jenny Chapman (2002) [2000]. Digital Multimedia. Wiley. p. 70. ISBN 0-471-98386-1.
- ^ CS 354 Vector Graphics & Path Rendering Archived April 18, 2020, at the Wayback Machine, Slide 7, By Mark Kilgard, April 10, 2012, University of Texas at Austin
- ^ Rex van der Spuy (2010). AdvancED Game Design with Flash. Apress. p. 306. ISBN 978-1-4302-2739-7.
- ^ Ted Landau (2000). Sad Macs, Bombs and Other Disasters (4th ed.). Peachpit Press. p. 409. ISBN 978-0-201-69963-0.
- ^ Amy Arntson (2011). Graphic Design Basics (6th ed.). Cengage Learning. p. 194. ISBN 978-1-133-41950-1.
- ^ Barr 1984, p. 21.
- ^ SVG Working Group (March 15, 2011). "SVG Compositing Specification". w3. Archived from the original on August 7, 2022. Retrieved August 8, 2022.
- ^ Qin, Zheng (January 27, 2009). Vector Graphics for Real-time 3D Rendering (PDF) (Thesis). University of Waterloo. p. 1. hdl:10012/4262. Archived (PDF) from the original on July 28, 2020. Retrieved July 28, 2020.
- ^ "Stock Photos Websites Market Report | Global Forecast From 2023 To 2032". datasetsearch.research.google.com. April 2023. Retrieved August 25, 2024.
- ^ Says, Studyessay org (March 21, 2022). "7 of the Best Vector Sites for Graphic Designers". Spoon Graphics. Retrieved August 25, 2024.
References
[edit]- Barr, Alan H. (July 1984). "Global and local deformations of solid primitives" (PDF). Proceedings of the 11th annual conference on Computer graphics and interactive techniques. Vol. 18. pp. 21–30. CiteSeerX 10.1.1.67.6046. doi:10.1145/800031.808573. ISBN 0897911385. S2CID 16162806. Retrieved July 31, 2020.
- Gharachorloo, Nader; Gupta, Satish; Sproull, Robert F.; Sutherland, Ivan E. (July 1989). "A characterization of ten rasterization techniques" (PDF). Proceedings of the 16th annual conference on Computer graphics and interactive techniques. Vol. 23. pp. 355–368. CiteSeerX 10.1.1.105.461. doi:10.1145/74333.74370. ISBN 0201504340. S2CID 8253227. Retrieved July 28, 2020.
- Murray, Stephen (2002). "Graphic Devices". In Roger R. Flynn (ed.). Computer Sciences, Vol 2: Software and Hardware, Macmillan Reference USA. Gale eBooks. Retrieved August 3, 2020.
External links
[edit]- Media related to Vector graphics at Wikimedia Commons