SVG File (Scalable Vector Graphics)
SVG (Scalable Vector Graphics) is an Extensible Markup language-based vector image format for two-dimensional graphics with support for interactivity and animation. It was developed in 1999 by Wide Web Consortium.
SVG files are developed as a standard format for displaying vector graphics on the web. SVG is based on XML text. This means that the format depends on text to describe lines, curves, colors and other physical attributes of an image.
Given that text is used to describe the graphic, an SGV file can be scalable to different sizes without losing quality. This in fact explains why websites and print graphics are often built in the SGV format, so they can be resized to fit different designs in the future.
One among the best things about SVG images is that they do not get blurry when zoomed in, as opposed to raster images (JPEG, PNG & GIF) which get blurry easily due to their pixel-based format. This attribute of SGV files fit the current trend in web development which demands scalability and responsiveness. The most common examples of SGV are for Logos/icons, interactive graphics and animations.
What You Need To Know About SVG File
- SVG image is vector based.
- Generally looks great on super-high pixel density screens like most modern smartphones.
- SVG images are used in devices using high resolution images.
- SVG images use .svg extension
- SVG images are editable.
- SVG image quality remains same while zooming.
- SVG images are made up of paths and shapes.
- Not supported by all browsers and operating systems (famously IOS and older, simpler phones and browsers).
- Can be more difficult to create or manipulate for people unfamiliar with vector graphics.
- Format is resolution independent, infinitely scalable.
- Allows transparency backgrounds.
- Can be animated or otherwise manipulated as code.
- Allows very small file sizes for relatively simple shapes.
PNG File (Portable Network Graphics)
Portable Network Graphics (PNG) is a file format used for lossless image compression and is generally considered the replacement to the GIF image format. PNG was developed by an Internet Working Group headed by Thomas Boutell that came together in 1994 to begin creating the PNG format.
One good thing about PNG is that compression is lossless, which means that there is no loss in quality each time a file is opened and saved again. PNG is also good for detailed, high-contrast images. In this regard, PNG is typically the default format for screenshots because, instead of compressing groups of pixel together, it offers a nearly perfect pixel-for-pixel representation of the screen.
PNG files are often used to store web graphics, digital photographs and images with transparent backgrounds. Some operating systems like macOS and Ubuntu store screenshots in the PNG format by default.
The PNG format is widely used for saving images. Many types of computer users may encounter PNG files, whether downloading an image from a website, receiving a digital photo attached to an email or taking a screenshot. Graphics professionals may also save web graphics as PNG files or icon mockups with transparent backgrounds as PNG files.
Uses of PNG
PNG can be used for:
- Charts, graphs, logos, blueprints and architectural plans
- Photos or scans of text, such as handwritten letters or newspaper articles
- Photos with line art such as drawings, illustrations and comics.
- Anything with text such as page layouts made in Photoshop or in design then saved as images.
What You Need To Know About PNG File
- PNG is pixel based.
- Generally do not look good on high quality/high-density screens unless you oversize.
- PNG images are generally used in image creation.
- PNG images use .npg extension.
- PNG images are not editable.
- PNG image quality degrades while zooming.
- PNG images are made up of pixels.
- Compatible with most browsers and operating systems.
- Can be made with many different pixel-based graphic editors.
- Resolution is limited to whatever size you created the file at.
- Support transparency. Supports compression of digital images with transparent areas.
- Cannot be animated/manipulated like SVGs because they are bitmaps.
- Supports a large number of colors. The format is suitable for different types of digital images including photographs and graphics.
- Sharp edges and solid colors. This makes it ideal for images containing texts, line arts and graphics.
Difference Between SVG File And PNG File In Tabular
|BASIS OF COMPARISON||SVG FILE||PNG FILE|
|Description||SVG image is vector based.||PNG is pixel based.|
|Outlook||Generally looks great on super-high pixel density screens like most modern smartphones.||Generally do not look good on high quality/high-density screens unless you oversize.|
|Use||SVG images are used in devices using high resolution images.||PNG images are generally used in image creation.|
|Extension||SVG images use .svg extension||PNG images use .npg extension.|
|Ability To Edit||SVG images are editable.||PNG images are not editable.|
|Image Quality On Zooming||SVG image quality remains same while zooming.||PNG image quality degrades while zooming.|
|Image Content||SVG images are made up of paths and shapes.||PNG images are made up of pixels.|
|Browser Compatibility||Not supported by all browsers and operating systems (famously IOS and older, simpler phones and browsers).||Compatible with most browsers and operating systems.|
|Manipulation||Can be more difficult to create or manipulate for people unfamiliar with vector graphics.||Can be made with many different pixel-based graphic editors.|
|Resolution||Format is resolution independent, infinitely scalable.||Resolution is limited to whatever size you created the file at.|
|Transparency||Allows transparency backgrounds.||Support transparency. Supports compression of digital images with transparent areas.|
|Animation||Can be animated or otherwise manipulated as code.||Cannot be animated/manipulated like SVGs because they are bitmaps.|
Also Read: Difference Between JPEG And PNG