Bitmap 和 Pixmap 有什么区别?
位图和像素图有什么区别?位图和像素图的文件扩展名是什么?
What is the difference between Bitmap and pixmap?also what is the file extension of bitmap and pixmap?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
参考
查看此处了解有关 PixMap 的更多信息。
文件扩展名
位图是 .BMP
像素图是 .XPM
Reference
Look at here to read more about PixMap.
File extensions
bitmap is .BMP
pixmaps is .XPM
一方面,Pixmap是像素图,因此它是由像素组成的存储区域。另一方面,Pixmap用于绘图,因此它是一个2d矩形区域,可以在其中进行绘图。
话虽这么说,唯一需要理解的是绘图是如何进行的?答案是通过设置PIxmap的像素来进行绘制,这就引出了一个问题:什么是像素?
与计算机中的所有内容一样,像素只是一个数值。数值在计算机中使用位来表示,因此像素是一系列位。当仅使用一位来表示一个像素时,这称为位图。
像素是一个数值,它代表什么?你可能会问。简单来说,它代表一种颜色。 1位可以表示两种颜色,两位可以表示四种颜色,n位可以表示2的n次方颜色。
此数字像素值映射到颜色方案,因此您可以有多种颜色方案,例如黑白、不同强度的单色以及 RGB 等彩色方案。
例如,在 RGB 中,数字像素值可以表示光的强度,混合在一起形成最终的颜色,就像用电子束撞击红色、绿色、蓝色磷材料一样。
On one side, a Pixmap is a pixel map, so it is a memory area formed of pixels. On the other side, a Pixmap is used for drawing, so it is a 2d rectangular area, where drawing is possible.
This being said, the only thing which is left to understand, is how drawing is performed? The answer is that drawing is performed by setting the pixels of a PIxmap, which leads to the question what is a pixel?
As with everything in a computer, a pixel is just a numeric value. A numeric value is represented in the computer by using bits, so a pixel is a series of bits. When only one bit is used to represent a pixel, this is called a bitmap.
A pixel is a numeric value, which represents what? you might ask. Simply put, it represents a color. 1 bit can represent two colors, two bits can represent four colors, and n bits can represent 2 to the power n colors.
This numeric pixel value, maps to a color scheme, so you have multiple color schemes, for example black and white, monochrome with different intensities, and colorful color schemes such as RGB.
So, for example, in RGB, the numeric pixel value, can represent intensities of light, mixed together to form the final color, like by having a red, green, blue phosphorus material, hit with electron beams.
有单色位图和颜色位图。
位图是单色位图的代名词。
pixmap是颜色位图的代名词。
graymap是颜色位图的同义词。
单色位图使用1位存储颜色,因此最大2种颜色。
颜色位图使用几个位来存储颜色。它专用的每个像素越多,pixmap / graymap /颜色位图支持的颜色就越多。
There are monochrome bitmaps and color bitmaps.
Bitmap is a synonym to a monochrome bitmap.
Pixmap is a synonym to a color bitmap.
Graymap is a synonym to a color bitmap.
Monochrome bitmaps use 1 bit to store a color, hence max 2 colors.
Color bitmaps use several bits for storing a color. The more bits per pixel it dedicates, the more colors this pixmap / graymap / color bitmap will support.