当前位置:网站首页>TGA file format (waveform sound file format)
TGA file format (waveform sound file format)
2022-07-25 20:05:00 【Full stack programmer webmaster】
Hello everyone , I meet you again , I'm your friend, Quan Jun .
Tga Common formats are uncompressed RGB And compression RGB Two formats , The third of the document Byte Bit as a marker :2 Is uncompressed RGB Format ,10 For compression RGB Format . The classes here only implement reading in uncompressed format tga file .
Given first tga The file format of the file :
name | The offset | length | explain | ||
|---|---|---|---|---|---|
Length of image information field | 0 | 1 | This field is 1 Byte unsigned integer , Point out the image information field ( See the back of this sub table ) length , Its value range is 0 To 255 , When it's for 0 When there is no image information field . | ||
Color table type | 1 | 1 | 0 Indicates that there is no color table ,1 Indicates that the color table exists . Because this format has no color table , Therefore, this item is usually ignored . | ||
Image type code | 2 | 1 | This field is always 2 , This is also the format of this type 2 Why . | ||
Color table specification field | The first address of the color table | 3 | 2 | The entry index at the beginning of the color table , integer ( Low position - High position ) | If the color table field is 0, Then ignore the field |
The length of the color table | 5 | 2 | The total number of items in the color table , integer ( Low position – High position ) | ||
Number of color table entries | 7 | 1 | digit (bit),16 representative 16 position TGA ,24 representative 24 position TGA ,32 representative 32 position TGA | ||
Image specification field | Images X Coordinate starting position | 8 | 2 | Lower left corner of the image X Integer of coordinates ( Low position – High position ) value | |
Images Y Coordinate starting position | 10 | 2 | Lower left corner of the image Y Integer of coordinates ( Low position – High position ) value | ||
The width of the image | 12 | 2 | In pixels , Integer of image width ( Low position – High position ) | ||
Height of the image | 14 | 2 | In pixels , Integer of image width ( Low position – High position ) | ||
Image storage occupancy per pixel | 16 | 2 | Its value is 16,24 or 32 wait . Determines that the image is TGA 16,TGA24,TGA 32 wait . | ||
Image descriptor bytes | 17 | 1 | bits 3-0 – The number of attribute bits per pixel ; about TGA 16, The value is 0 or 1, about TGA 24, The value is 0, about TGA 32, The value is 8. bit 4 – Retain , It has to be for 0 bit 5 – Screen start position flag 0 = The origin is in the lower left corner 1 = Origin in the upper left corner about truevision The image must be 0 bits 7-6 – Cross data storage flag 00 = No cross 01 = Two roads / Even crossing 10 = Four way intersection 11 = Retain | ||
Image information field | 18 | variable | Contains a free-form , The length of the image is determined by “ Image information field ” Appoint . It is often overlooked ( That is, offset 0 The value at is 0 ), Note that it can contain 255 Characters . If you need to store more information , It can be placed after the image data . | ||
Color table data | variable | variable | If the color table type is 0, Then the domain does not exist , Otherwise, read the number of bytes of each item in the image color table specification directly across this field , by 2,3,4 One of . | ||
Image data | variable | variable | RGB Color data , The storage order is :BBB GGG RRR (AAA) | ||
Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/127750.html Link to the original text :https://javaforall.cn
边栏推荐
- What is idealism
- Interpretation of repartitioned network structure in repvgg network [with code]
- Apache MINA框架「建议收藏」
- 连接数据库警告 Establishing SSL connection without server‘s identity verification is not recommended.
- 分享 25 个有用的 JS 单行代码
- Siemens PLM Teamcenter download, installation and use tutorial
- Do you still have certificates to participate in the open source community?
- wallys//wifi6 wifi5 router IPQ6018 IPQ4019 IPQ4029 802.11ax 802.11ac
- Error when creating dataset with mindscore
- Shopping guide for high-end flagship projectors: dangbei X3 pro and dangbei F5 are more immersive!
猜你喜欢
![PMP adopts the latest exam outline, here is [agile project management]](/img/72/d3e46a820796a48b458cd2d0a18f8f.png)
PMP adopts the latest exam outline, here is [agile project management]

随机梯度下降法、牛顿法、冲量法、AdaGrad、RMSprop以及Adam优化过程和理解

wallys//IPQ5018/IPQ6010/PD-60 802.3AT Input Output 10/100/1000M

4everland storage node portal network design

导电滑环在机械设备方面的应用

Recommendations on how to install plug-ins and baby plug-ins in idea

Socket error Event: 32 Error: 10053. Connection closing...Socket close
![[cloud native | learn kubernetes from scratch] VIII. Namespace resource quotas and labels](/img/7e/2bdead512ba5bf5ccd0830b0f9b0f2.png)
[cloud native | learn kubernetes from scratch] VIII. Namespace resource quotas and labels

Advantages of network virtualization of various manufacturers
![Partial interpretation of yolov7 paper [including my own understanding]](/img/80/95d00565c4ec89a388ae4386801a02.png)
Partial interpretation of yolov7 paper [including my own understanding]
随机推荐
【高等数学】【4】不定积分
[mindspore] [read graph data] cannot read mindrecord format graph data
Application of conductive slip ring in mechanical equipment
Detailed evaluation of current popular redis visual management tools
Creative drop-down multi choice JS plug-in download
4. Server startup of source code analysis of Nacos configuration center
CarSim仿真快速入门(十六)—CarSim传感器仿真之ADAS Sensor Objects (2)
Day7: ordered binary tree (binary search tree)
Successfully solved typeerror: a bytes like object is required, not 'str‘
String of sword finger offer question bank summary (II) (C language version)
CarSim simulation quick start (XV) - ADAS sensor objects of CarSim sensor simulation (1)
Split very long line of words into separate lines of max length
How to get started quickly in software testing
Mobile phone touch picture slider rotation plug-in photoswipe.js
Mutual conversion of camera internal parameter matrix K and FOV
Do you still have certificates to participate in the open source community?
How to ensure the quality of customized slip rings
tiktok手机网络环境怎么设置?tiktok怎么破播放量?
Socket error Event: 32 Error: 10053. Connection closing...Socket close
redis源码 -ziplist