jonsth131 / ggtool Goto Github PK
View Code? Open in Web Editor NEWTools for ggpack files used in Return to Monkey Island
License: MIT License
Tools for ggpack files used in Return to Monkey Island
License: MIT License
Also ggtool doesnt convert all ktxbz to png, there are many skipped ones.
a few examples:
LowStreetBackHouse1Lamp-hd.ktxbz
BeachHermitCrab-hd.ktxbz
ArrivePart4-hd.ktxbz
and many others
Could you please add decompress and compress methods to ggtool?
PNG to KTXBZ
KTXBZ to PNG
Thanks
Maybe we should consider converting the ktx-textures to something like png?
KTX is a Khronos file format for sending prepared textures to the GPU. Looking at the RTMI-textures, they seem to be compressed with BPTC which is a format the GPU can decompress on the fly.
I couldn't find much about decompressing BPTC, except for this repo which contains C-code for decompressing them:
https://github.com/hglm/detex
I we're really motivated, we could port it to a sys-crate.
Another option is to create an OpenGL context and render the texture to a renderTexture to "read-it-back" so to speak. It can then be encoded to png with the png-crate.
Would this also work with macOS version? Or itβs only fir Windows?
Getting this error while extracting some files. The KTXBZ file gets extracted, but not the PNG.
Extracting Locksmith1-hd.ktxbz. Size = 11416, offset = 1088884480
Inflating...
Decompressing BPTC texture...
thread 'main' panicked at 'Contexts must be destroyed explicitly with `destroy_context`!', /Users/myusername/.cargo/registry/src/github.com-1ecc6299db9ec823/surfman-0.4.3/src/platform/macos/cgl/context.rs:95:13
Note: Build was compiled with "decompress_ktx"
$ ~/ggtool extract-files Weird.ggpack1a "*" extracted/
Extracting AbandonedPirateCamp.wimpy. Size = 8170, offset = 16
Extracting AbandonedShip.wimpy. Size = 14696, offset = 8192
Extracting Alley.wimpy. Size = 4082, offset = 22896
Extracting AlleyPart5.wimpy. Size = 4023, offset = 26992
Extracting BLANK.yack. Size = 227, offset = 31024
Extracting BarPirates.yack. Size = 6338, offset = 31264
Extracting BarebonesIsland.wimpy. Size = 7221, offset = 37616
Extracting BelowCliff.wimpy. Size = 12181, offset = 44848
Extracting BelowCliff.yack. Size = 17840, offset = 57040
Extracting Blizzard.emitter. Size = 2362, offset = 74880
Extracting BlizzardOverview.emitter. Size = 2683, offset = 77248
Extracting BlizzardQuarry.emitter. Size = 2364, offset = 79936
Extracting Bonfire.emitter. Size = 4051, offset = 82304
Extracting Bonfire2.emitter. Size = 8135, offset = 86368
Extracting BonfireDistant.emitter. Size = 7814, offset = 94512
Extracting BonfireScumm.emitter. Size = 6870, offset = 102336
Extracting BottleBubbles.emitter. Size = 2251, offset = 109216
Extracting BrrrMudaOverview.wimpy. Size = 3998, offset = 111472
thread 'main' panicked at '1 is not a known GGValueType', libdinky/src/directory.rs:34:18
note: run with RUST_BACKTRACE=1
environment variable to display a backtrace
list-files works...
[
"AbandonedPirateCamp.wimpy",
"AbandonedShip.wimpy",
"Alley.wimpy",
"AlleyPart5.wimpy",
"BLANK.yack",
"BarPirates.yack",
"BarebonesIsland.wimpy",
"BelowCliff.wimpy",
"BelowCliff.yack",
"Blizzard.emitter",
"BlizzardOverview.emitter",
"BlizzardQuarry.emitter",
"Bonfire.emitter",
"Bonfire2.emitter",
"BonfireDistant.emitter",
"BonfireScumm.emitter",
"BottleBubbles.emitter",
"BrrrMudaOverview.wimpy",
"Bubbles.emitter",
"BubblesBlowfish.emitter",
"BubblesPlungeFloodedCave.emitter",
"BubblesPlungeOffshore.emitter",
"BubblesPlungeUnderShip.emitter",
"BubblesStream.emitter",
too long to paste it all...
There are several KTXBZ files that I am unable to extract. The error seems related with the BZ compression.
Extracting MonkeyHead2-hd.ktxbz. Size = 9530480, offset = 1006135040
Inflating...
thread 'main' panicked at 'Failed to inflate compressed data: "unknown ZLIB method CM=0x0"', libdinky/src/ggpack.rs:136:52
Hi there, currently using MacOS 12.6.
ggtool v0.1.0
Getting the following error when trying to extract EndStingers_1-hd.ktxbz
from Weird.ggpack5a
:
Error when inflating, "unknown ZLIB method CM=0xf", saving raw data.
Other ktxbz files don't have this error. Seems like there might be something unique about the "EndStingers_" series of files. (Although I'm getting a blank PNG with other ktxbz files.)
Your NEW ggtool doesnt make PNG anymore... I have to use old one to make it work.
Please fix it.
Example: extract 5a or 5b ggpack from RTMI. ktxbz is not converted at all. Png doesnt exist.
Functionality to extract data from bank files.
Can you please release windows or linux binaries?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.