js 图片格式转换为jpg_如何将图像转换为JPG格式

js 图片格式转换为jpg

js 图片格式转换为jpg

Many websites have strict rules that limit the size and type of image format you’re allowed to upload. With JPG being the go-to file format of the internet, we’re going to take a look at how you can convert your images into JPG format.

许多网站都有严格的规则,这些规则限制了您允许上传的图像格式的大小和类型。 JPG是Internet的常用文件格式,我们将研究如何将图像转换为JPG格式。

什么是JPG文件? (What Is a JPG File?)

JPG (or JPEG), is a popular file format used for images and graphics—especially on the internet. It was created by the Joint Photographic Experts Group (JPEG) and uses a compression algorithm that reduces sections of an image into blocks of pixels. It’s able to compress up to a ratio of 10:1 without any noticeable degradation, depending on your settings. This alone is one of the main reasons why JPG has become the de facto standard of images on the internet.

JPG(或JPEG)是一种流行的文件格式,用于图像和图形,尤其是在Internet上。 它由联合图像专家组(JPEG)创建,并使用压缩算法将图像的各个部分缩小为像素块。 根据您的设置,它可以压缩至10:1的比例而不会出现任何明显的降级。 仅此一点就是JPG成为互联网上事实上的图像标准的主要原因之一。

However, all that compression doesn’t come without a loss. JPGs are considered a “lossy” file format, meaning that during the compression procedure, redundant blocks are permanently deleted. The more you compress a file, the more data you lose and subsequently the worse your final image is going to look after multiple iterations through the algorithm.

但是,所有这些压缩并非没有损失。 JPG被认为是“有损”文件格式 ,这意味着在压缩过程中,冗余块将被永久删除。 压缩文件的次数越多,丢失的数据就越多,随后经过该算法的多次迭代后,最终图像将变得越差。

Here’s an example of an image that has been way overcompressed.

这是过度压缩图像的示例。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值