|
JubeatPlus 3.9.11
|
The bundled-resource texture and image loaders. More...

Go to the source code of this file.
Functions | |
| NS_ASSUME_NONNULL_BEGIN UIImage *_Nullable | CreateImageFromEncryptedData (BFCodec *cipher, NSMutableData *encryptedData) |
Decrypts an encrypted image blob in place and builds a UIImage from it. | |
| BOOL | LoadTextureSubImageFromResource (Texture2D *texture, NSString *resourceName, CGPoint point) |
| Loads a bundled PNG and blits it into an existing texture atlas at a point. | |
| BOOL | LoadTextureSubImageFromEncryptedTex (Texture2D *texture, NSString *resourceName, BFCodec *cipher, CGPoint point) |
Decrypts a bundled .tex asset and blits it into an existing texture atlas at a point. | |
| Texture2D *_Nullable | CreateTexture2DFromPngResource (NSString *resourceName) |
Vends a fully-populated Texture2D atlas from a bundled PNG plus its sprite-rect plist. | |
| Texture2D *_Nullable | CreateTexture2DFromEncryptedTexResource (NSString *resourceName, BFCodec *cipher) |
Vends a Texture2D atlas from an encrypted .tex asset plus its plaintext plist. | |
The bundled-resource texture and image loaders.
Reconstructed from Ghidra program Jubeat (image base 0x100000000). All
These five routines form one contiguous cluster in the binary (0x124ce8..0x125448) that turns a bundled asset into a Texture2D atlas, a texture sub-image, or a plain UIImage . Each takes its collaborators — the texture, the BFCodec cipher — as explicit arguments and none carries a self / _cmd pair, so they are genuine C free functions rather than methods of Texture2D or BFCodec ; the reconstruction rules' search for an owning class is exhausted (the two CreateTexture2DFrom* factories vend a Texture2D but are not registered in its runtime method table, exactly as LoadScaledPngImage is not a UIImage method). No embedded __FILE__ has been located, so this file's name is this tree's own; it is recorded in TYPES_PENDING.md as unproven.
The encrypted variants all skip a fixed four-byte header that precedes the image payload, and read their sprite-rect .plist unencrypted even when the image itself is enciphered.
| NS_ASSUME_NONNULL_BEGIN UIImage *_Nullable CreateImageFromEncryptedData | ( | BFCodec * | cipher, |
| NSMutableData * | encryptedData ) |
Decrypts an encrypted image blob in place and builds a UIImage from it.
Deciphers encryptedData through cipher — which rewrites the buffer in place — then builds an image from the payload after a fixed four-byte header. The header skip is unconditional and unvalidated, so a plaintext buffer fed here loses its first four bytes and yields nil .
| cipher | The Blowfish codec, already keyed. |
| encryptedData | The ciphertext. Mutated in place by the decrypt. |
nil when the decrypt failed. | Texture2D *_Nullable CreateTexture2DFromEncryptedTexResource | ( | NSString * | resourceName, |
| BFCodec * | cipher ) |
Vends a Texture2D atlas from an encrypted .tex asset plus its plaintext plist.
The encrypted twin of CreateTexture2DFromPngResource . Only the image bytes pass through cipher ; the sprite-rect .plist is read unencrypted.
| resourceName | The base name shared by the .tex and .plist , without an extension. |
| cipher | The Blowfish codec, already keyed. |
nil . | Texture2D *_Nullable CreateTexture2DFromPngResource | ( | NSString * | resourceName | ) |
Vends a fully-populated Texture2D atlas from a bundled PNG plus its sprite-rect plist.
Loads resourceName as a .png, wraps it in a Texture2D , then sets the sprite table from the matching .plist . A missing .plist fails the whole load even when the PNG decoded; the two files must ship as a pair.
| resourceName | The base name shared by both files, without an extension. |
nil . | BOOL LoadTextureSubImageFromEncryptedTex | ( | Texture2D * | texture, |
| NSString * | resourceName, | ||
| BFCodec * | cipher, | ||
| CGPoint | point ) |
Decrypts a bundled .tex asset and blits it into an existing texture atlas at a point.
The encrypted twin of LoadTextureSubImageFromResource : reads the .tex, deciphers it through cipher , skips the four-byte header, and blits the decoded image into texture at point .
| texture | The atlas to patch. |
| resourceName | The bundle resource name, without the .tex extension. |
| cipher | The Blowfish codec, already keyed. |
| point | The destination origin in texels. |
YES on success; NO if the resource was missing, the decrypt failed, or the bytes were not a valid image. | BOOL LoadTextureSubImageFromResource | ( | Texture2D * | texture, |
| NSString * | resourceName, | ||
| CGPoint | point ) |
Loads a bundled PNG and blits it into an existing texture atlas at a point.
Resolves resourceName as a .png in the main bundle and, if present, draws it into texture at point . A missing resource leaves the atlas untouched and returns NO .
| texture | The atlas to patch. |
| resourceName | The bundle resource name, without the .png extension. |
| point | The destination origin in texels. |
YES when the resource existed and was blitted, NO otherwise.