Skip to content

Commit fa9c2c2

Browse files
authored
Update README.md
1 parent b1bedac commit fa9c2c2

1 file changed

Lines changed: 64 additions & 20 deletions

File tree

README.md

Lines changed: 64 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ For now, it allows you to edit files in these formats
4242
- `.model` (JSON only full mode and metadata editing mode)
4343
- `.nei`
4444

45-
Current Game Version COM3D2 v2.45.0 & COM3D2.5 v3.45.0
45+
Current Game Version COM3D2 v2.46.3 & COM3D2.5 v3.46.3
4646

4747
| Extension | Description | Version Support | Note |
4848
|-----------|-----------------------|--------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
@@ -173,23 +173,25 @@ Releases: [https://github.com/MeidoPromotionAssociation/COM3D2_MOD_EDITOR/releas
173173
- `failed to write to .nei file: failed to encode string: encoding: rune not supported by encoding.`
174174

175175
- About version 1011 of the .tex file
176-
- __New fields__: Version 1011 adds a `Rects` (texture atlas) array to the binary structure. Its elements are four `float32` values: `x, y, w, h`, representing rectangles in normalized UV space.
177-
- __When converting an image to `.tex`:
178-
- If a `.uv.csv` file with the same name exists in the same directory (e.g., `foo.png.uv.csv`), the rectangles in it will be read and the 1011 version of the tex file will be generated.
179-
- If no `.uv.csv` file exists, the 1010 version (without `Rects`) will be generated.
180-
- __When converting `.tex` to an image__:
181-
- If the source `.tex` is 1011 and contains `Rects`, a `.uv.csv` file with the same name will be generated next to the output image (e.g., `output.png.uv.csv`).
182-
- __.uv.csv format__:
183-
- Encoding must be: UTF-8 with BOM.
184-
- Delimiter: English comma `,`.
185-
- Number of columns: 4 columns per row, in the order `x, y, w, h` (x, y, width, height); values are typically in the range `[0, 1]` (normalized UVs). It is recommended to retain up to 6 decimal places and use `float32` precision.
186-
Example:
187-
188-
```csv
189-
0.000000,0.000000,0.500000,0.500000
190-
0.500000,0.000000,0.500000,0.500000
191-
0.000000,0.500000,0.500000,0.500000
192-
```
176+
- New fields:
177+
- Version 1011 adds a `Rects` (texture atlas) array to the binary structure. Its elements are four `float32` values: `x, y, w, h`, representing rectangles in normalized UV space.
178+
- When converting an image to `.tex`:
179+
- If a `.uv.csv` file with the same name exists in the same directory (e.g., `foo.png.uv.csv`), the rectangles in it will be read and the 1011 version of the tex file will be generated.
180+
- If no `.uv.csv` file exists, the 1010 version (without `Rects`) will be generated.
181+
- When converting `.tex` to an image:
182+
- If the source `.tex` is 1011 and contains `Rects`, a `.uv.csv` file with the same name will be generated next to the output image (e.g., `output.png.uv.csv`).
183+
- .uv.csv format:
184+
- Encoding must be: UTF-8 with BOM.
185+
- Delimiter: English comma `,`.
186+
- Number of columns: 4 columns per row, in the order `x, y, w, h` (x, y, width, height); values are typically in the range `[0, 1]` (normalized UVs). It is recommended to retain up to 6 decimal places and use `float32` precision.
187+
Example:
188+
189+
```csv
190+
x,y,w,h
191+
0.000000,0.000000,0.500000,0.500000
192+
0.500000,0.000000,0.500000,0.500000
193+
0.000000,0.500000,0.500000,0.500000
194+
```
193195
194196
- About CSV format
195197
- All CSV files used in this program are encoded using UTF-8-BOM, separated by ',', and follow the [RFC4180](https://datatracker.ietf.org/doc/html/rfc4180) standard.
@@ -375,6 +377,27 @@ COM3D2 MOD 编辑器,使用 Golang + Wails + React + TypeScript 打造,现
375377
- `failed to write to .neiData file: failed to encode string: encoding: rune not supported by encoding.`
376378
- `failed to write to .nei file: failed to encode string: encoding: rune not supported by encoding.`
377379
380+
- 关于 1011 版本的 .tex
381+
- 新增字段:
382+
- 1011 版本在二进制结构中新增 `Rects`(纹理图集)数组,元素为 `x, y, w, h` 四个 `float32`,表示归一化 UV 空间内的矩形。
383+
- 将图片转换为 `.tex` 时:
384+
- 若同目录存在同名的 `.uv.csv`(如 `foo.png.uv.csv`),会读取其中的矩形并生成 1011 版本的 tex。
385+
- 若不存在 `.uv.csv`,则生成 1010 版本(不含 `Rects`)。
386+
- 将 `.tex` 转换为图片时:
387+
- 若源 `.tex` 为 1011 且包含 `Rects`,在输出图片旁会生成同名 `.uv.csv`(如 `output.png.uv.csv`)
388+
- .uv.csv 格式:
389+
- 编码必须为:UTF-8-BOM。
390+
- 分隔符:英文逗号`,`。
391+
- 列数:每行 4 列,依次为 `x, y, w, h` (x, y, width, heigh);取值通常位于区间 `[0,1]`(归一化 UV),建议保留最多 6 位小数,精度为
392+
`float32`。
393+
- 示例:
394+
```csv
395+
x,y,w,h
396+
0.000000,0.000000,0.500000,0.500000
397+
0.500000,0.000000,0.500000,0.500000
398+
0.000000,0.500000,0.500000,0.500000
399+
```
400+
378401
- 关于 CSV 格式
379402
- 本程序中使用的所有 CSV 文件均采用 UTF-8-BOM 编码,以“,”分隔,并遵循 [RFC4180](https://datatracker.ietf.org/doc/html/rfc4180) 标准。
380403
@@ -445,7 +468,7 @@ KISSはこれらのゲームを制作する会社/ブランドです
445468
- `.model` (JSONの完全スキーマとメタデータ編集モード)
446469
- `.nei`
447470
448-
対応ゲームバージョン COM3D2 v2.45.0 および COM3D2.5 v3.45.0
471+
対応ゲームバージョン COM3D2 v2.46.3 および COM3D2.5 v3.46.3
449472
450473
| 拡張子 | 説明 | 対応バージョン | 備考 |
451474
|--------|-------------|----------------|---------------------------------------------------------------------------------------------------------------------|
@@ -561,6 +584,27 @@ Releasesからダウンロードしてください:[https://github.com/MeidoPr
561584
- `failed to write to .neiData file: failed to encode string: encoding: rune not supported by encoding.`
562585
- `failed to write to .nei file: failed to encode string: encoding: rune not supported by encoding.`
563586
587+
- .tex ファイルのバージョン1011について
588+
- 新しいフィールド:
589+
- バージョン1011では、バイナリ構造に`Rects`(テクスチャアトラス)配列が追加されました。その要素は4つの`float32`値:`x, y, w, h`で、正規化されたUV空間の矩形を表します。
590+
- 画像を`.tex`に変換する場合:
591+
- 同じディレクトリに同じ名前の`.uv.csv`ファイルが存在する場合(例:`foo.png.uv.csv`)、その中の矩形が読み取られ、1011バージョンのtexファイルが生成されます。
592+
- `.uv.csv`ファイルが存在しない場合は、(`Rects`のない)1010バージョンが生成されます。
593+
- `.tex`を画像に変換する場合:
594+
- ソースの`.tex`が1011で`Rects`を含んでいる場合、出力画像の隣に同じ名前の`.uv.csv`ファイルが生成されます(例:`output.png.uv.csv`)。
595+
- .uv.csvのフォーマット:
596+
- エンコーディング:UTF-8 with BOMでなければなりません。
597+
- デリミタ:英語のカンマ`,`。
598+
- 列数:各行に4列、`x, y, w, h`(x, y, 幅, 高さ)の順番。値は通常`[0, 1]`の範囲(正規化UV)です。小数点以下6桁まで保持し、`float32`精度を使用することをお勧めします。
599+
例:
600+
601+
```csv
602+
x,y,w,h
603+
0.000000,0.000000,0.500000,0.500000
604+
0.500000,0.000000,0.500000,0.500000
605+
0.000000,0.500000,0.500000,0.500000
606+
```
607+
564608
- CSV形式について
565609
- このプログラムで使用されるすべてのCSVファイルは、UTF-8-BOMでエンコードされ、「,」で区切られており、[RFC4180](https://datatracker.ietf.org/doc/html/rfc4180)標準に準拠しています。
566610
@@ -601,7 +645,7 @@ Releasesからダウンロードしてください:[https://github.com/MeidoPr
601645
# How to Dev
602646
603647
1. Clone this repo, and cd to project root
604-
2. Install [Golang](https://go.dev/) 1.24+
648+
2. Install [Golang](https://go.dev/) 1.25+
605649
3. Run `go install github.com/wailsapp/wails/v2/cmd/wails@latest`
606650
4. Install [Nodejs](https://nodejs.org/) v22 lts
607651
5. Install Pnpm `npm install -g pnpm@latest-10`

0 commit comments

Comments
 (0)