Do near-final touches, should of done this last commit but oh well.
Actually made C6JS C6JS and not node-specific. Didn't know there was a difference.
This commit is contained in:
parent
4e27befc6f
commit
95172cf285
68
README.md
68
README.md
|
@ -1,30 +1,38 @@
|
||||||
# icondumper2 (working title)
|
# icondumper2 (working title)
|
||||||
A JavaScript library (sorta) to read PS2 icons, and their related formats.
|
A JavaScript library (sorta) to read PS2 icons, and their related formats.
|
||||||
|
|
||||||
## What it supports
|
## What it supports
|
||||||
* EMS Memory Adapter export files (.psu)
|
* EMS Memory Adapter export files (.psu)
|
||||||
* PS3 virtual memory card export files (.psv)
|
* PS3 virtual memory card export files (.psv)
|
||||||
* SharkPort export files (.sps)
|
* SharkPort export files (.sps)
|
||||||
* X-Port export files (.xps)
|
* X-Port export files (.xps)
|
||||||
* PS2 icons (.ico, .icn)
|
* PS2 icons (.ico, .icn)
|
||||||
* PS2D format (icon.sys)
|
* PS2D format (icon.sys)
|
||||||
|
|
||||||
## What can it do
|
## What can it do
|
||||||
* Allow any file in a PSU's or SPS/XPS's virtual filesystem to be dumped.
|
* Allow any file in a PSU's or SPS/XPS's virtual filesystem to be dumped.
|
||||||
* Warn of invalid icon.sys display names.
|
* Warn of invalid icon.sys display names.
|
||||||
* Read and parse an EMS MA export file.
|
* Read and parse an EMS MA export file.
|
||||||
* Export the icon model, with all seperate shapes included to a JavaScript Object.
|
* Export the icon model, with all seperate shapes included to a JavaScript Object.
|
||||||
* Node.js compatible (CommonJS) exporting while still being compatible with other JavaScript implementations.
|
* Node.js compatible (CommonJS) exporting while still being compatible with other JavaScript implementations.
|
||||||
* Convert a 128x128x16 BGR5A1 bitmap to a RGB5A1 format.
|
* Convert a 128x128x16 BGR5A1 bitmap to a RGB5A1 format.
|
||||||
* Convert an icon or a set of icons to glTF, with textures.
|
* Convert an icon or a set of icons to glTF, with textures.
|
||||||
|
|
||||||
## What it doesn't do
|
## What it doesn't do
|
||||||
* (Re)build save files.
|
* (Re)build save files.
|
||||||
* Modify the original input files.
|
* Modify the original input files.
|
||||||
* Use any Node.js-exclusive features.
|
* Use any Node.js-exclusive features.
|
||||||
|
|
||||||
## Client compatibility
|
## Client compatibility
|
||||||
(todo: write this)
|
(todo: write this)
|
||||||
|
|
||||||
## Why "icondumper2"?
|
## Why "icondumper2"?
|
||||||
Because it replaced what *was* left of icondumper (1).
|
Because it replaced what *was* left of icondumper (1).
|
||||||
|
|
||||||
|
## Included files
|
||||||
|
| File | Description |
|
||||||
|
| ---- | ----------------------------------------- |
|
||||||
|
| icon.js | The library itself. |
|
||||||
|
| index.js | Node.js example client. |
|
||||||
|
| gltf-exporter.js | Node.js client to export icons to glTF 2. |
|
||||||
|
| index.htm | HTML reference client. |
|
||||||
|
|
17
icon.js
17
icon.js
|
@ -590,13 +590,14 @@ function readSharkXPortSxpsFile(input) {
|
||||||
return fsOut;
|
return fsOut;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** If we have a module object, define module.exports with all public functions */
|
/** Define (module.)exports with all public functions */
|
||||||
|
exports = {
|
||||||
|
readers: {readIconFile, readPS2D, readEmsPsuFile, readPsvFile, readSharkXPortSxpsFile},
|
||||||
|
helpers: {uncompressTexture, convertBGR5A1toRGB5A1},
|
||||||
|
options: {setDebug, setStrictness},
|
||||||
|
version: ICONJS_VERSION
|
||||||
|
};
|
||||||
|
|
||||||
if(typeof module !== "undefined") {
|
if(typeof module !== "undefined") {
|
||||||
// for C6JS
|
module.exports = exports;
|
||||||
module.exports = {
|
|
||||||
readers: {readIconFile, readPS2D, readEmsPsuFile, readPsvFile, readSharkXPortSxpsFile},
|
|
||||||
helpers: {uncompressTexture, convertBGR5A1toRGB5A1},
|
|
||||||
options: {setDebug, setStrictness},
|
|
||||||
version: ICONJS_VERSION
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,6 +19,7 @@
|
||||||
#titlebox {width: 99%;position: absolute;}
|
#titlebox {width: 99%;position: absolute;}
|
||||||
input[type="file"] {line-height: 2em;}
|
input[type="file"] {line-height: 2em;}
|
||||||
#version {text-shadow: 1px 1px 2px black;}
|
#version {text-shadow: 1px 1px 2px black;}
|
||||||
|
a {color: #ccc;}
|
||||||
</style>
|
</style>
|
||||||
<meta data-comment="WebGL Shader: Icon">
|
<meta data-comment="WebGL Shader: Icon">
|
||||||
<script type="text/plain" id="shader-icon-v">
|
<script type="text/plain" id="shader-icon-v">
|
||||||
|
@ -631,11 +632,11 @@
|
||||||
}
|
}
|
||||||
//todo: More than one model shape rendering, other 2 icons (technically done? NMW though), Animation parsing, animation tweening
|
//todo: More than one model shape rendering, other 2 icons (technically done? NMW though), Animation parsing, animation tweening
|
||||||
</script>
|
</script>
|
||||||
<span id="version">icondumper2 <span id="iconjsVersion">(unknown icon.js version)</span> [C: <span id="clientVersion">Loading...</span>] — © <span id="currentYear">2023</span> yellows111</span>
|
<span id="version">icondumper2 <a href="./documentation" id="iconjsVersion">(unknown icon.js version)</a> [C: <span id="clientVersion">Loading...</span>] — © <span id="currentYear">2023</span> yellows111</span>
|
||||||
<script>
|
<script>
|
||||||
document.getElementById("iconjsVersion").textContent = ICONJS_VERSION;
|
document.getElementById("iconjsVersion").textContent = exports.version;
|
||||||
document.getElementById("clientVersion").textContent = "0.6.5";
|
document.getElementById("clientVersion").textContent = "0.6.5";
|
||||||
document.getElementById("currentYear").textContent = (new Date()).getFullYear().toString();
|
document.getElementById("currentYear").textContent = (new Date()).getFullYear().toString();
|
||||||
</script>
|
</script>
|
||||||
</body>
|
</body>
|
||||||
</html>
|
</html>
|
Loading…
Reference in New Issue