File
CGrfArchive, CFileSystem, CResourceMgr, CResourceCache, LZ4, zlib, libpng, ZipWriter, OLE/BIFF/Excel, CMemMappedFile
| Address | Size | Name | Description |
|---|---|---|---|
| 0x004012B0 | 20 | CFileReader__init_vtable | Initializes CFileReader vtable, zeros size/error/buffer fields |
| 0x004012D0 | 42 | CFileReader__reset_and_free_buffer | Resets CFileReader error and size fields, frees buffer at offset 0xc |
| 0x00401300 | 202 | CFileReader__open_file_wide | Opens file via CreateFileW for reading, gets file size with GetFileSizeEx |
| 0x00401730 | 113 | CFileReader__read_data_from_buffer | Reads data from CFileReader internal buffer, sets error codes 1 or 3 |
| 0x00401870 | 4 | CFileReader__get_file_size | Returns CFileReader file size from offset 0x8 |
| 0x00401880 | 4 | CFileReader__get_error_code | Returns CFileReader error code from offset 0x4 |
| 0x00401890 | 48 | CFileReader__cleanup_and_free | Resets CFileReader vtable, zeros fields, frees buffer at offset 0xc |
| 0x004018C0 | 89 | CFileReader__open_file_ansi | Converts ANSI filename to wide char then calls open_file_wide |
| 0x00401920 | 178 | CFileReader__load_with_hash_check | Loads file and verifies MD5 hash from data+size params |
| 0x004019E0 | 210 | CFileReader__load_file_with_md5_check | Opens wide file, computes MD5 hash via mmap, then reads buffer |
| 0x00401AC0 | 68 | CFileReader__destructor | CFileReader destructor: resets vtable, frees buffer, optional scalar delete |
| 0x00401B10 | 148 | CFileReader__load_ansi_with_hash_check | Converts ANSI path to wide, loads file with MD5 verification |
| 0x00401BB0 | 131 | CFileReader__load_ansi_with_md5_check | Converts ANSI path to wide, loads file with MD5 check via mmap |
| 0x0044BEC0 | 225 | CResourceMgr__init_sprite_manager | Inits sprite resource manager vtable, registers as sprite type |
| 0x0044BFB0 | 225 | CResourceMgr__init_model_manager | Inits model resource manager vtable, registers as model type |
| 0x0044C1A0 | 157 | CResourceMgr__init_generic_mgr_0044c1a0 | Inits resource manager for unnamed type, registers with system |
| 0x0044C340 | 123 | CResourceMgr__init_texture_mgr_a | Inits texture resource manager instance A |
| 0x0044C3C0 | 123 | CResourceMgr__init_texture_mgr_b | Inits texture resource manager instance B |
| 0x0044C440 | 123 | CResourceMgr__init_texture_mgr_c | Inits texture resource manager instance C |
| 0x0044C4C0 | 123 | CResourceMgr__init_texture_mgr_d | Inits texture resource manager instance D |
| 0x0044C540 | 204 | CResourceMgr__init_texture_mgr_complex | Inits texture manager with extended fields, registers with system |
| 0x0044C710 | 137 | CResourceMgr__init_emblem_manager | Inits emblem texture resource manager for tmpEmblem files |
| 0x0044C8A0 | 282 | CResourceMgr__init_texture_effect_mgr | Inits texture effect manager with 0x380 array, STL string |
| 0x0044CAC0 | 344 | CResourceMgr__init_complex_resource_mgr | Inits complex resource manager with STL string at offset |
| 0x0044CD20 | 157 | CResourceMgr__init_named_mgr_0044cd20 | Inits named resource manager, registers with system |
| 0x0044CEC0 | 299 | CResourceMgr__init_model_list_mgr | Inits model resource manager with two linked lists for tracking |
| 0x0044CFF0 | 153 | CResourceMgr__init_3dmob_model_mgr | Inits 3D mob model resource manager, registers as model_3dmob |
| 0x0044D090 | 123 | CResourceMgr__init_model_variant_mgr | Inits model variant resource manager with custom constructor |
| 0x0057B940 | 54 | CFileStream__close_handle | Closes file handle or frees stream buffer |
| 0x0057B980 | 404 | CFileStream__read_and_decrypt | Reads and decrypts file data |
| 0x0057BB50 | 203 | CFileSystem__file_exists_check | Checks if file exists |
| 0x0057BC20 | 1034 | CFileSystem__normalize_path | Normalizes file path |
| 0x0057C030 | 431 | CFileStream__open | Opens file for reading/writing |
| 0x0057C1E0 | 125 | CFileStream__read | Reads bytes from file stream |
| 0x0057C260 | 107 | CFileStream__read_with_advance | Reads bytes and advances position |
| 0x0057C2D0 | 97 | CFileStream__seek | Cfilestream: seek, small utility function |
| 0x0057C340 | 50 | CFileStream__write | Writes bytes to file |
| 0x005B8410 | 236 | CFileStream__open_csv_file | Opens file for CSV reading; validates path, detects BOM encoding, skips UTF-8 BOM, rejects UTF-16 |
| 0x005ED5B0 | 29 | CGrfFileRecord__copy_range_backward | Copies a range of GRF file record data backward (from end to adjusted position). Used for shifting elements during vector insert operations. Computes destination as param_3 - (param_2 - param_1). |
| 0x005ED5D0 | 29 | CGrfFileRecord__copy_range_backward_B | Copies a range of GRF file record data backward. Identical implementation to copy_range_backward at 005ed5b0 - separate instantiation for a different element type. |
| 0x005ED5F0 | 34 | CGrfFileRecord__copy_range_forward | Copies a range of bytes forward via memcpy. Returns pointer past the end of the destination. Used in GRF file record vector operations. |
| 0x005EE270 | 423 | CGrfFileRecord__make_heap | Builds a max-heap from an array of 0x120-byte GRF file records (Floyd's algorithm). Starts from the middle element and sifts down each element. Uses CGrfFileRecord__compare_less_than for ordering. Part of STL sort implementation for GRF files. |
| 0x005EE420 | 207 | CGrfFileRecord__median_of_three_sort | Performs median-of-three selection and sorting for 3 GRF file record elements. Compares and swaps elements to place the median in the middle position. Used as pivot selection for introsort. Element size: 0x120 bytes (72 dwords). |
| 0x005EE4F0 | 34 | CGrfFileRecord__copy_range_forward_B | Copies a range of bytes forward via memcpy. Returns pointer past end of destination. Same as CGrfFileRecord__copy_range_forward but separate template instantiation. |
| 0x005EE520 | 34 | CGrfFileRecord__copy_range_forward_C | Copies a range of bytes forward via memcpy. Returns pointer past end of destination. Same as CGrfFileRecord__copy_range_forward but another template instantiation. |
| 0x005EE550 | 990 | CGrfFileRecord__introsort_partition | Introsort partition (Hoare scheme) for 0x120-byte GRF file records. Selects pivot via median-of-three, then partitions array into elements less than and greater than pivot. Returns partition boundaries via param_1 output array. Handles equal-to-pivot elements specially to avoid worst-case behavior. |
| 0x005EE930 | 255 | CGrfFileRecord__heap_sift_down | Heap sift-down operation for 0x120-byte GRF file records. Moves an element down the heap from position param_2 until heap property is restored. Compares children, swaps with larger child, then sifts the displaced element back up. Element size: 72 dwords. |
| 0x005EEA30 | 692 | CGrfFileRecord__introsort | Hybrid introsort for 0x120-byte GRF file records. Uses quicksort with median-of-three pivot selection. Falls back to heapsort when recursion depth (param_3) reaches 0. Uses insertion sort for small ranges (<0x21 elements / 0x2520 bytes). Recursion depth reduced by 3/4 each level. |
| 0x005EECF0 | 52 | CGrfFileRecord__copy_range_to_dest | CGrfFileRecord: copy range to dest |
| 0x005EEED0 | 67 | CGrfArchive__delete_node_12bytes | Deletes a 12-byte (0xC) heap allocation stored at offset+4 of the object. Part of CGrfArchive tree node cleanup. SEH protected. |
| 0x005EEF20 | 67 | CGrfArchive__delete_node_32bytes | Deletes a 32-byte (0x20) heap allocation stored at offset+4 of the object. Part of CGrfArchive tree node cleanup. SEH protected. |
| 0x005EEF70 | 67 | CGrfArchive__delete_node_32bytes_v2 | Deletes a 32-byte (0x20) heap allocation stored at offset+4 of the object. Duplicate of 005eef20 with different SEH unwind label. Part of CGrfArchive tree node cleanup. |
| 0x005EEFC0 | 67 | CGrfArchive__delete_node_40bytes | Deletes a 40-byte (0x28) heap allocation stored at offset+4 of the object. Part of CGrfArchive tree node cleanup. SEH protected. |
| 0x005EF010 | 78 | CGrfArchive__delete_node_12bytes_v2 | Deletes a 12-byte (0xC) heap allocation stored at offset+4 of the object. Variant with different SEH unwind setup order. Part of CGrfArchive tree node cleanup. |
| 0x005EF060 | 111 | CGrfArchive__destroy_linked_list_and_sentinel | Iterates a linked list of 0x20-byte nodes, calls a cleanup function on each node's data (offset+8), deletes each node, then deletes the sentinel node. Part of CGrfArchive tree/list destruction. |
| 0x005EF0E0 | 76 | CGrfArchive__destroy_tree_and_sentinel_40bytes | Destroys a red-black tree by calling stub_005edbd0 to erase all child nodes from the root, then frees the 0x28-byte sentinel node. Part of CGrfArchive cleanup. |
| 0x005EF140 | 78 | CGrfArchive__delete_node_32bytes_v3 | Deletes a 32-byte (0x20) heap allocation stored at offset+4 of the object. Variant with different SEH unwind setup. Part of CGrfArchive tree node cleanup. |
| 0x005EF190 | 78 | CGrfArchive__delete_node_32bytes_v4 | Deletes a 32-byte (0x20) heap allocation stored at offset+4 of the object. Another variant with different SEH unwind setup. Part of CGrfArchive tree node cleanup. |
| 0x005EF1E0 | 104 | CGrfArchive__destroy_node_with_string_40bytes | Destroys a 0x28-byte node that contains an embedded std::string. First destructs the string via STL_string_dtor, then frees the 40-byte allocation. Part of CGrfArchive tree node cleanup. |
| 0x005EF250 | 78 | CGrfArchive__delete_node_32bytes_v5 | Deletes a 32-byte (0x20) heap allocation stored at offset+4 of the object. Yet another variant with different SEH unwind label. Part of CGrfArchive tree node cleanup. |
| 0x005EF2A0 | 78 | CGrfArchive__delete_node_32bytes_v6 | Deletes a 32-byte (0x20) heap allocation stored at offset+4. Part of CGrfArchive tree node cleanup. |
| 0x005EF2F0 | 78 | CGrfArchive__delete_node_40bytes_v2 | Deletes a 40-byte (0x28) heap allocation stored at offset+4. Part of CGrfArchive tree node cleanup. |
| 0x005EF340 | 65 | CGrfArchive__destroy_linked_list_wrapper | Wrapper that calls CGrfArchive__destroy_linked_list_and_sentinel (005ef060) to destroy the linked list. SEH protected wrapper. |
| 0x005EF390 | 87 | CGrfArchive__destroy_tree_and_sentinel_40bytes_v2 | Destroys a red-black tree by erasing all child nodes from the root, then frees the 0x28-byte sentinel node. Variant of 005ef0e0 with different SEH unwind setup. |
| 0x005EF400 | 100 | CGrfArchive__dtor_base | CGrfArchive base destructor. Sets vtable to derived class vtable, calls cleanup function (005f7810), deallocates a vector buffer, then sets vtable to base class (_Facet_base). Does NOT free the object itself. |
| 0x005EF470 | 107 | CGrfArchive__dtor_complete | CGrfArchive complete destructor. Like dtor_base (005ef400) but with additional cleanup steps (state index 2 vs 1). Sets vtable, calls cleanup, deallocates vector, resets to base vtable. |
| 0x005EF5A0 | 94 | CGrfArchive__compare_file_offset | Compares two GRF file offset entries. Compares first field (uint), then compares a 64-bit offset composed of fields at index 2 and 3. Returns 1 if first < second, 0 otherwise. Used for sorting/searching file offsets in the GRF archive. |
| 0x005EF600 | 93 | CGrfArchive__compare_file_record_key | Compares two GRF file record keys. Compares a 64-bit value (fields 0+1), then if equal, compares field 2 as a tiebreaker. Returns 1 if first < second, 0 otherwise. Used for tree ordering of file records. |
| 0x005EF690 | 121 | CGrfArchive__scalar_deleting_dtor | CGrfArchive scalar deleting destructor. Calls full destructor (cleanup, vector dealloc, vtable reset to base), then optionally frees the 0x20-byte object if bit 0 of param is set. |
| 0x005EF710 | 128 | CGrfArchive__scalar_deleting_dtor_v2 | CGrfArchive scalar deleting destructor variant. Uses state index 2 for more thorough cleanup, then optionally frees the 0x20-byte object if bit 0 of param is set. |
| 0x005EF790 | 188 | CGrfArchive__add_grf_entry_to_list | Adds a GRF entry (param_2) to the linked list at this+0x148. Allocates a 0xC-byte list node, stores the entry pointer at node+8, links it into the doubly-linked list. Increments count at this+0x14C. Throws std::_Xlength_error if list is at max capacity (0x15555555). Then updates the file name set at this+0x150. |
| 0x005EF850 | 330 | CGrfArchive__reset_all_entries | Resets the CGrfArchive to empty state. Calls cleanup on internal data, resets GRF entry state via CGrfEntry__reset_state, iterates the GRF entry list (this+0x148) calling virtual destructors on each entry, frees all list nodes, reinitializes the linked list sentinel, clears the file name tree (this+0x150), shrinks/deallocates multiple vectors (file records at 0x24/0x30, gap list at 0x158) and resets their sizes. |
| 0x005EF9A0 | 21254 | CGrfArchive__init_des_encryption_tables | CGrfArchive: init des encryption tables |
| 0x005F4CB0 | 790 | CGrfArchive__build_free_space_map | Builds a free-space (gap) map for the GRF archive. Starts with offset 0x2E (after GRF header), adds the archive's own offset range (this+0x18..0x20), then iterates file records at this+0x24 adding each file's offset+0x2E with its size. For each gap between entries, inserts a node into a red-black tree (free space map). Finally checks total file size and adds trailing free space if needed. |
| 0x005F4FD0 | 477 | CGrfArchive__read_and_decrypt_file_data | Reads file data from a GRF entry and optionally decrypts it. Reads raw data via virtual call on this+8. If file is compressed (flag bit 7), just copies raw data. Otherwise builds a DES key from the filename, generates DES subkeys, and decrypts using either single-pass (flag & 4) or multi-pass (flag & 2) DES encryption based on a digit-count cipher mode. Clears encryption flags and copies result to output buffer. |
| 0x005F51B0 | 81 | CGrfArchive__build_filename_index | Iterates all file records in the vector at (param+0x24..param+0x28) with 0x120-byte stride. For each record that has a file extension (strrchr for '.'), adds its filename to an index/set structure. Used to build a filename lookup for the GRF archive. |
| 0x005F5210 | 164 | CGrfArchive__allocate_space_for_file | Allocates space in the GRF archive for a file of given size. Searches the free-space tree (this+0x164) for a gap that fits. If no gap found, gets the total archive size and returns the end-of-file offset. If a gap is found but larger than needed, splits the gap and adds the remainder back. Removes the used gap node from the tree. Returns the allocated offset as a 64-bit value. |
| 0x005F52C0 | 134 | CGrfArchive__calculate_total_file_data_size | Iterates all nodes in the free-space tree (this+0x164) and sums up the size field (offset+0x10) of each node. Returns the total size as a 64-bit value. This computes the total amount of file data stored in the GRF archive. |
| 0x005F5350 | 125 | CGrfArchive__read_file_table_from_entries | Reads the file table by iterating GRF entries in the linked list (this+0x148). For each entry, calls CGrfEntry__read_file_table_data. Stops when data is read successfully (param_2[1] != param_2[0]). If no entry provides data, falls back to copying from a default buffer at this+0x194..0x198. Reserves more space in the output vector if needed. |
| 0x005F53D0 | 1508 | CGrfArchive__save_archive | Saves the GRF archive to disk (1,508 bytes). Calls init_des_encryption_tables, then build_free_space_map. Iterates all file names in the tree (this+0x150), setting each file record's name. For each file, reads the entry data, sorts records, serializes file record headers and data into a byte buffer, compresses with zlib, reads the existing file table, allocates space for the compressed table + file table, writes the compressed table header (12 bytes: file_table_size, compressed_size, uncompressed_size), writes compressed data, writes file table, and writes the 'Event Horizon' GRF header at offset 0x1E with file count and version 0x300. Reports progress via callback. |
| 0x005F59C0 | 71 | CGrfArchive__open_and_load | Opens a GRF archive file and loads its contents. Calls open_file (005f7890), then parses the GRF header via CGrfEntry__parse_header_and_load on the file handle at this+0x170, and reads the file table data into buffer at this+0x194. Returns 1 on success, 0 on failure. |
| 0x005F5A10 | 2307 | CGrfArchive__import_grf_and_merge | Imports files from another GRF archive and merges them into this archive (2,307 bytes). Opens the source GRF, reads its 'Event Horizon' header, iterates file entries in the source tree, for each file: reads its name, finds the corresponding record, allocates a decompression buffer, calls read_and_decrypt_file_data, allocates space in this archive, writes the file data to the new location, serializes file record headers, compresses the file table with zlib, reads the existing file table, writes header+compressed table+file table, then writes the GRF header with updated file count. Reports progress via callback. |
| 0x005F6320 | 594 | CGrfArchive__add_or_replace_file | Adds or replaces a file in the GRF archive (594 bytes). Iterates GRF entries looking for a file record matching the given name. If found, reads and decrypts the file data, allocates space in the archive, writes the data at the allocated offset, then binary-searches the file record vector to find the insertion/replacement point. If record exists, overwrites it; if not, appends to the record vector (expanding at this+0x158..0x15C). Returns 1 on success, 0 on failure. |
| 0x005F66F0 | 123 | CGrfArchive__alloc_aligned_buffer | Allocates an aligned byte buffer for GRF file data. For sizes < 0x1000, does a simple allocation. For sizes >= 0x1000, allocates size+0x23 bytes and aligns the result to a 32-byte boundary, storing the original allocation pointer at aligned_ptr-4 for later freeing. Initializes a 3-element vector header (base, end, capacity). Throws on overflow or allocation failure. |
| 0x005F6770 | 122 | CGrfArchive__replace_file_record_vector | Replaces the file record vector's backing buffer. Frees the old buffer (handling aligned allocations >= 0x1000 via the stored original pointer at base-4). Replaces with new buffer pointer param_2, setting count = param_3 * 0x120 + base and capacity = param_4 * 0x120 + base. 0x120 is the size of one GRF file record. |
| 0x005F67F0 | 704 | CGrfArchive__rbtree_erase_node | Red-black tree node erasure for CGrfArchive's free-space tree (704 bytes). Standard RB-tree deletion: finds successor, splices out the node, performs rotations and recoloring to maintain RB-tree invariants. Handles all cases: node with two children (swap with successor), node with one child, leaf node. Decrements the tree size counter. Returns the removed node pointer (caller must free it). |
| 0x005F6AB0 | 3 | CGrfArchive__identity_return | Identity function that returns its parameter unchanged. 3-byte function (just returns param_1). Likely a trivial converter or type-cast stub in the CGrfArchive subsystem. |
| 0x005F7150 | 260 | CGrfArchive__reallocate_byte_buffer | Reallocates a byte buffer (vector-like). Allocates a new buffer of specified size (with 32-byte aligned allocation for sizes >= 0x1000), copies existing data from old buffer, frees the old buffer, and updates the vector header (base, used, capacity). Used for growing byte vectors in CGrfArchive operations. |
| 0x005F73A0 | 151 | CGrfArchive__free_file_record_vector | Frees the file record vector's backing buffer. Handles aligned allocations (>= 0x1000) by reading the original allocation pointer at base-4. Zeroes out the vector header (base, used, capacity). Part of CGrfArchive cleanup. 0x120 is the file record stride. |
| 0x005F7440 | 36 | CGrfArchive__memcpy_file_records | Copies file record data from source range [param_1, param_2) to destination param_3 via memcpy. Returns the new destination end pointer (param_3 + bytes_copied). Used during file record vector reallocation to copy existing records to a new buffer. |
| 0x00643330 | 109 | CFileSystem__resize_cipher_output_buffer | Resizes the output buffer (offset 0x20) to match the size returned by the vtable method at offset 0x8. Calls resize_cipher_buffers first to resize the other two internal buffers. |
| 0x006433A0 | 182 | CFileSystem__resize_cipher_buffers | Resizes two internal cipher buffers (offsets 0x8 and 0x14) to match the size returned by the vtable method. Zero-fills any new space. Part of cipher state initialization. |
| 0x00643460 | 21 | CFileSystem__finalize_cipher | Finalizes cipher and clears key material |
| 0x00643480 | 46 | CFileSystem__setup_aes_context | Sets up AES context with key and IV |
| 0x006434B0 | 331 | CFileSystem__xor_buffers | XORs two source buffers (param_2, param_3) into destination (param_1) for param_4 bytes. Processes 16 bytes at a time in the fast path, with SIMD-unrolled 64-byte inner loop when buffers don't overlap. Used as a building block for CBC-mode XOR step. |
| 0x00643600 | 260 | CFileSystem__xor_buffer_inplace | XORs buffer param_2 into buffer param_1 in-place for param_3 bytes. Processes 16 bytes at a time, with SIMD-unrolled 64-byte inner loop for non-overlapping buffers. Used for CBC-mode decryption XOR step. |
| 0x00643710 | 221 | CFileSystem__bswap32_buffer | Byte-swaps an array of 32-bit integers from param_2 into param_1. Processes param_3/4 dwords. Uses SSSE3 pshufb for fast 16-byte batches, scalar fallback reverses bytes via shifts. Converts between big-endian and little-endian representation. |
| 0x00643860 | 17 | CFileSystem__is_encryption_enabled | Returns whether file encryption is enabled |
| 0x00643CC0 | 17 | CFileSystem__is_compression_enabled | CFileSystem: is compression enabled |
| 0x00644130 | 29 | CFileSystem__get_cipher_block_size | Returns cipher block size for current mode |
| 0x0065C940 | 87 | CResourceCache__expire_old_entries | Removes expired entries from the timed deque. Entries older than 60 seconds (60000ms via timeGetTime) are popped from the front. Decrements count and advances front index. |
| 0x0065C9A0 | 225 | CResourceCache__deque_find_and_pop | Searches the pair-deque for a matching (key1, key2) entry using a secondary lookup table. If found, pops from front via deque_pop_front and returns the pair. If not found, returns (0,0). |
| 0x0065CA90 | 252 | CResourceCache__deque_push_back | Searches the pair-deque for an existing (param_2, param_3) entry. If not found, grows the buffer if needed and appends the new pair at the back. Allocates 0x10 byte blocks for storage. |
| 0x0065CB90 | 415 | CResourceCache__process_and_register_sky_texture | Combines expire_old_entries + deque_find_and_pop. If a matching entry is found, calls CSkyDataProviderB__register_sky_texture with the pair values, timestamps it via timeGetTime, and pushes to the timed deque (with 12-byte entries: pair + timestamp). |
| 0x0065CD30 | 417 | CResourceCache__deque_grow_buffer_8byte | Grows the circular deque buffer for 8-byte elements (pairs). Doubles capacity, allocates new aligned buffer, copies existing data preserving circular layout, frees old buffer. Throws _Xlength_error if overflow. |
| 0x0065CEE0 | 400 | CResourceCache__deque_grow_buffer_12byte | Grows the circular deque buffer for 12-byte elements (pair + timestamp). Same doubling/copy/free logic as the 8-byte variant. Used by the timed entry deque. Throws _Xlength_error if overflow. |
| 0x0065D0A0 | 18 | CResourceCache__deque_pop_front | Pops the front element from the deque. Decrements count at offset+0x10. If count becomes 0, resets front index to 0. Otherwise advances front index at offset+0xc. |
| 0x0065D760 | 272 | CResourceCache__ctor | CResourceCache constructor. Initializes: vtable, rbtree with 0x1c head node (uint set), rbtree with 0x28 head node (string map), deque/vector (blocks 9-11), max_size=0xC800, creates file handle via CPacketStream__construct_0065c5f0. |
| 0x0065DBC0 | 200 | CResourceCache__dtor | CResourceCache destructor. Sets vtable, destroys file handle (virtual call), frees deque blocks, destroys string map rbtree (0x28 nodes with strings), destroys uint set rbtree (0x1c nodes). SEH protected with staged cleanup. |
| 0x0065DC90 | 68 | CResourceCache__deque_free_blocks | Frees the deque block array via STL_vector_dealloc_raw_buffer_v2. SEH protected wrapper used during CResourceCache destruction. |
| 0x0065DED0 | 221 | CResourceCache__scalar_deleting_dtor | CResourceCache scalar deleting destructor. Cleans up file handle, deque blocks, string map rbtree, uint set rbtree, then optionally frees 0x34 bytes of memory if param_2 & 1. |
| 0x0065DFB0 | 623 | CResourceCache__register_directory_entry | Registers a file path in the directory-keyed string map. Extracts directory prefix (up to last backslash). Looks up the directory in the rbtree; if not found, inserts a new node. Uses Insert_node for rbtree insertion. Checks map size limit (0x6666666). |
| 0x0065E220 | 109 | CResourceCache__create_file_handle | Creates a new file handle object (0x2C bytes) via CPacketStream__construct_0065c5f0 and stores it at this+0x10. Returns true if allocation succeeded. |
| 0x0065E290 | 373 | CResourceCache__get_or_create_instance | Singleton accessor for CResourceCache. Creates instance at global DAT_0138cf20 if null. Initializes full CResourceCache (rbtrees, deque, file handle). Returns 1 on success, 0 on failure (destroys instance if file handle creation fails). |
| 0x0065E410 | 25 | CResourceCache__destroy_file_handle | Destroys the file handle object at this+0x10. Calls virtual destructor (vtable[0]) with delete flag=1, then nulls the pointer. |
| 0x0065E430 | 27 | CResourceCache__destroy_singleton | Destroys the CResourceCache singleton at DAT_0138cf20. Calls virtual destructor with delete flag=1, then nulls the global pointer. |
| 0x0065E450 | 491 | CResourceCache__load_resource_file | Loads a resource file by ID. Uses _Find_lower_bound to search the uint rbtree. If found and value > 0, builds cache path, gets CResourceMgr instance, and loads via CResourceMgr__load_resource_by_string. Falls back to secondary rbtree if first load fails and DAT_016f7144==0. Returns result as std::string. |
| 0x0065E640 | 65 | CResourceCache__lookup_by_id | Looks up a resource ID in the uint rbtree using _Find_lower_bound. Returns the associated value (at node+0x18) if found, 0 otherwise. |
| 0x0065E690 | 95 | CResourceCache__insert_or_update_by_id | Inserts or updates a uint rbtree entry. Looks up key via _Find_lower_bound. If found, updates the value by calling deque_push_back. If not found, also calls deque_push_back with value=0. |
| 0x0065E6F0 | 414 | CResourceCache__has_directory_entry | Checks if a file path's directory exists in the string map rbtree. Extracts directory prefix (up to last backslash), looks up in rbtree via STL_rbtree_lower_bound_string. Returns true if directory entry found, false otherwise. |
| 0x0065E890 | 1132 | CResourceCache__compress_and_save_to_file | Major file caching function. Formats a string (vsnprintf), builds cache path, compresses data via zlib. Creates output directory if needed (_mkdir). Opens stringstream, writes header + compressed size. Iterates directory files, deleting old cache entries (_chmod+_unlink). Writes compressed data to file via fopen/fwrite/fclose. Falls back to register_directory_entry on compression failure. |
| 0x0065ED00 | 309 | CResourceCache__build_cache_path | Builds a cache file path using stringstream. Reads base path from global DAT_01732d98 (std::string), appends separator and version/hash (param_2 with 0x7FFFFFFF offset), converts to std::string via str(). Result stored in param_1. |
| 0x0065EE40 | 8 | CResourceCache__process_sky_texture_static | Static wrapper that calls CResourceCache__process_and_register_sky_texture. Simple thunk/forwarding function (8 bytes). |
| 0x0065EE50 | 66 | CResourceCache__notify_ui_window | Notifies a UI window after resource loading. Calls get_field4_if_mode1 to check mode, processes multibyte string if active (mbstr_to_wstr_and_process_b). Finds UI window type 0x3C via CUIWindowMgr and calls virtual method at vtable+0x98. |
| 0x0065EEA0 | 245 | CResourceCache__set_id_map_entry | Sets/inserts an entry in the uint-keyed rbtree (std::map<uint, value>). Uses _Find_lower_bound to locate insertion point. If key not found, allocates a 0x1c byte node, inserts via Insert_node. Sets value at node+0x18 to param_3. Throws if map exceeds 0x9249249 entries. |
| 0x0065F2B0 | 151 | CResourceCache__entry_ctor | CResourceCache entry constructor. Copies vtable from param_3, zeros 0x30 bytes of fields, initializes two SSO strings (capacity=0xF) and three counters to 0. Entry size is 0x34 bytes. |
| 0x006E8060 | 51 | LZ4__set_dictionary_stream | Sets external dictionary buffer for LZ4 streaming compression context |
| 0x006E80A0 | 80 | LZ4__compress_default | LZ4 default compression with auto-calculated max output size bound |
| 0x006E80F0 | 44 | LZ4__compress_bound | Returns worst-case compressed size for given input size, 0 if too large |
| 0x006E8120 | 65 | LZ4__compress_fast_extstate | LZ4 fast compression using external state buffer, auto-calculated bound |
| 0x006E8170 | 27 | LZ4__compress_dest_size_wrapper | Wrapper for LZ4 compression with explicit destination size limit |
| 0x006E8190 | 67 | LZ4__compress_dest_size_stack | LZ4 compression with stack-allocated 16KB hash table for destination-size mode |
| 0x006E81E0 | 2831 | LZ4__compress_generic_small | LZ4 core compression for small inputs (<64KB), uses 16-bit hash table entries |
| 0x006E8D60 | 69 | LZ4__compress_fast_stack | LZ4 fast compression with stack-allocated 16KB state buffer |
| 0x006E8DB0 | 8670 | LZ4__compress_generic_large | LZ4 core compression for large inputs (>64KB), uses 32-bit hash table with acceleration |
| 0x006EAF90 | 4947 | LZ4__compress_generic_full | Full LZ4 compression with configurable acceleration, handles both small and large inputs |
| 0x006EC3D0 | 4805 | LZ4__compress_HC | LZ4 high-compression mode with optimal match search for better ratios |
| 0x006EE180 | 2831 | LZ4__compress_HC_optimal | LZ4 HC optimal parsing compression for maximum compression ratio |
| 0x006EEC90 | 27 | LZ4__compress_fast_with_dest_size | LZ4 fast compression wrapper with explicit destination size, acceleration=1 |
| 0x006EECB0 | 30 | LZ4__compress_extstate_large | LZ4 compression using external state for large buffers, acceleration=1 |
| 0x006EECD0 | 30 | LZ4__compress_extstate_full | LZ4 full compression using external state buffer, acceleration=1 |
| 0x006EECF0 | 65 | LZ4__compress_fast_auto_bound | LZ4 fast compression with auto-calculated output bound, acceleration=1 |
| 0x006EEDB0 | 39 | LZ4__decode_bound | Returns max decompressed size for given compressed input size, min 16 bytes |
| 0x006EEDE0 | 245 | LZ4__decompress_safe | LZ4 safe decompression with bounds checking, returns compressed bytes consumed |
| 0x006EEEE0 | 489 | LZ4__decompress_safe_continue | LZ4 streaming decompression with dictionary continuation support |
| 0x006EF0D0 | 333 | LZ4__decompress_safe_with_dict | LZ4 safe decompression using external dictionary for back-references |
| 0x006EF220 | 285 | LZ4__decompress_safe_partial | LZ4 partial decompression with dictionary prefix support |
| 0x006EF340 | 245 | LZ4__decompress_safe_64k | LZ4 safe decompression for data compressed with 64KB window limit |
| 0x006EF440 | 1549 | LZ4__decompress_fast | LZ4 fast decompression with optimized copy loops, known output size |
| 0x006EFA50 | 2085 | LZ4__decompress_fast_continue | LZ4 fast streaming decompression with dictionary continuation |
| 0x006F0280 | 1982 | LZ4__decompress_fast_with_dict | LZ4 fast decompression using external dictionary for back-references |
| 0x006F0A40 | 1576 | LZ4__decompress_fast_partial_dict | LZ4 fast partial decompression with external dictionary support |
| 0x006F1070 | 1944 | LZ4__decompress_safe_partial_dict | LZ4 safe partial decompression with external dictionary support |
| 0x006F1810 | 132 | LZ4__decompress_dispatch | LZ4 decompression dispatcher: routes to LZ4__decompress_fast_partial_dict, LZ4__decompress_safe_partial_continue, LZ4__decompress_safe_partial_dict_continue, or LZ4__decompress_safe_partial_dict based on dictionary size and buffer adjacency. |
| 0x006F18A0 | 1561 | LZ4__decompress_safe_partial_continue | LZ4 safe partial decompression with 64KB sliding window. Reads literal/match tokens, copies literals, resolves back-references with bounds checking. Previously misnamed as compress_continue_generic. |
| 0x006F1EC0 | 1593 | LZ4__decompress_safe_partial_dict_continue | LZ4 safe partial decompression with external dictionary prefix. Similar to decompress_safe_partial_continue but handles dictionary-relative back-references. Previously misnamed as compress_continue_dest_size. |
| 0x006F2500 | 120 | LZ4__decompress_fast_dispatch | LZ4 fast decompression dispatcher: routes to LZ4__decompress_fast, LZ4__decompress_fast_optimized, LZ4__decompress_fast_dict_optimized, or LZ4__decompress_fast_with_dict based on dictionary params. |
| 0x006F2580 | 1550 | LZ4__decompress_fast_optimized | LZ4 fast decompression with optimized 16-byte/32-byte block copy loops and small-offset special handling. Uses known output size. Previously misnamed as compress_HC_continue. |
| 0x006F2B90 | 1566 | LZ4__decompress_fast_dict_optimized | LZ4 fast decompression with dictionary-relative back-references and optimized block copy loops. Uses known output size. Previously misnamed as compress_HC_continue_dest_size. |
| 0x006F31B0 | 24 | LZ4__stream_free_safe | Frees LZ4 stream state with null check, returns 0 |
| 0x006F31D0 | 24 | LZ4__decode_stream_free | Frees LZ4 decompression streaming state with null check |
| 0x006F31F0 | 51 | LZ4__init_stream_state | Initializes LZ4 stream state buffer, requires 4-byte alignment and min 0x4020 size |
| 0x006F3230 | 148 | LZ4__load_dict | Loads dictionary into LZ4 stream state, populates hash table from dict data |
| 0x006F32D0 | 131 | LZ4__renorm_dict_entries | Renormalizes LZ4 hash table entries when offset exceeds 2GB to prevent overflow |
| 0x006F3360 | 23 | LZ4__reset_stream_state | Zeroes out entire LZ4 stream state (0x4014 bytes) |
| 0x006F3380 | 25 | LZ4__reset_stream_and_return | Zeroes LZ4 stream state and returns 0 (success code) |
| 0x006F33A0 | 124 | LZ4__stream_reset_partial | Partial reset of LZ4 stream, clears hash table if mode changed or offset too large |
| 0x006F3420 | 79 | LZ4__save_dict | Copies last 64KB of dictionary from stream to external buffer for reuse |
| 0x006F3470 | 48 | LZ4__decode_stream_init | Initializes LZ4 decompression stream context with output buffer pointers |
| 0x006F34C0 | 14 | LZ4__get_stream_dict_ptr | Returns pointer to current dictionary base from LZ4 stream state |
| 0x006F34D0 | 9 | LZ4__decompress_safe_thunk | Thunk to LZ4_decompress_safe |
| 0x006F34E0 | 9 | LZ4__decompress_fast_thunk | Thunk to LZ4_decompress_fast |
| 0x006F3510 | 37 | LZ4__read_variable_length | Reads LZ4 variable-length integer from byte stream (0xFF continuation encoding) |
| 0x00732D60 | 80 | CFileLogger__ctor | Constructor for CFileLogger. Initializes vtable, sets log enabled flag, initializes critical section for thread safety, then calls initialize_log_file to set up the log directory and first log file. Object size is 0x834 bytes. |
| 0x00732DB0 | 65 | CFileLogger__dtor | Destructor for CFileLogger. Sets vtable and deletes the critical section. |
| 0x00732E00 | 93 | CFileLogger__scalar_deleting_dtor | Scalar deleting destructor for CFileLogger. Calls destructor, then optionally frees the 0x834-byte object. |
| 0x00732E70 | 1126 | CFileLogger__initialize_log_file | Initializes the file logger's log directory and file. Creates the log directory, generates a date-based filename pattern, cleans up old log files older than the cutoff date, then finds or creates the current log file. Supports file rotation when log exceeds 3MB (0x300000 bytes). Returns true if file index < 10000. |
| 0x007332E0 | 468 | CFileLogger__cleanup_old_logs | Cleans up old log files that are older than param_3 days. Searches the log directory for files matching the logger's prefix, compares filenames against a date-based cutoff string, and deletes (unlinks) any files that are too old. |
| 0x007334C0 | 797 | CFileLogger__write_log_entry | Writes a formatted log entry to the current log file. Thread-safe via scoped lock. Handles date rollover by creating new files when the date changes. Formats the entry with timestamp (YYYY-MM-DD HH:MM:SS.ms), source file, and line number. Rotates to a new file when size exceeds 3MB. |
| 0x007337F0 | 17 | CFileLogger__set_enabled | Sets the enabled flag for the file logger at offset +5. When disabled, conditional logging calls will not write to file. |
| 0x00733810 | 757 | CFileLogger__write_log_raw | Writes a raw string log entry (param_4 is the string, not varargs). Same log file rotation and timestamping logic as write_log_entry. Thread-safe with scoped lock. Only writes if logger and params are non-null. |
| 0x00733B10 | 807 | CFileLogger__write_log_if_enabled | Writes a formatted log entry only if the logger's enabled flag (offset +5) is set. Same logic as write_log_entry but with an additional enabled check. Thread-safe with scoped lock. |
| 0x00733E40 | 106 | CLoggerMap__destroy_tree_nodes | Recursively destroys all nodes in a red-black tree used by CLoggerMap. Each node is 0x814 bytes (contains an embedded CFileLogger). Traverses left subtrees recursively and right subtrees iteratively. |
| 0x00733EB0 | 75 | CLoggerMap__lower_bound | Performs a lower_bound search in the CLoggerMap's red-black tree. Searches for a node with key >= param_3. Returns an iterator-like struct with the found node, comparison result, and parent. |
| 0x00733F00 | 141 | CLoggerMap__ctor | Constructor for CLoggerMap (a std::map-like container for CFileLogger instances). Initializes vtable, creates a 0x814-byte sentinel/header node for the red-black tree, and initializes a critical section. Node count stored at offsets +7 and +8. |
| 0x00733F90 | 70 | CLoggerMap__free_sentinel_node | Frees the 0x814-byte sentinel node from the CLoggerMap tree if it exists. |
| 0x00733FE0 | 79 | CLoggerMap__clear_and_free | Clears all nodes from the CLoggerMap tree by calling destroy_tree_nodes on the root, then frees the sentinel node. |
| 0x00734040 | 81 | CLoggerMap__free_node_a | Frees a single 0x814-byte tree node from the CLoggerMap if the node pointer is non-null. |
| 0x007340A0 | 81 | CLoggerMap__free_node_b | Frees a single 0x814-byte tree node from the CLoggerMap if the node pointer is non-null. Duplicate of free_node_a, possibly for a different calling context. |
| 0x00734100 | 90 | CLoggerMap__clear_tree | Clears all nodes from the CLoggerMap tree by calling destroy_tree_nodes on the root subtree and then freeing the sentinel node (0x814 bytes). |
| 0x00734160 | 130 | CLoggerMap__dtor | Destructor for CLoggerMap. Sets vtable, deletes critical section, then destroys all tree nodes and frees the sentinel. |
| 0x007341F0 | 242 | CLoggerMap__find_or_insert | Finds an existing logger entry in the map by key, or inserts a new one if not found. Uses lower_bound to locate the position, allocates a 0x814-byte node (containing an embedded CFileLogger buffer of 0x800 bytes), and inserts into the red-black tree. Returns pointer to the logger data at node+0x14. |
| 0x007342F0 | 153 | CLoggerMap__scalar_deleting_dtor | Scalar deleting destructor for CLoggerMap. Calls destructor logic then optionally frees the 0x24-byte object. |
| 0x00734390 | 209 | CLoggerMap__get_thread_buffer | Gets or creates the per-thread log buffer. Uses the current thread handle as a key to look up in the CLoggerMap. If the thread's buffer doesn't exist yet, inserts a new zeroed 0x800-byte buffer. Thread-safe with scoped lock. |
| 0x0074C9D0 | 32 | png_read_callback | PNG read callback used with libpng. Wraps std::basic_istream::read to provide data from a stream to the PNG decoder. |
| 0x00755710 | 121 | CFileStreamEntry__ctor | Constructor for CFileStreamEntry. Sets vtable, initializes file handle to -1, zeroes buffer fields, initializes an SSO string. |
| 0x0076B873 | 239 | CFileReader__LoadWithMD5Check | Loads a file with MD5 integrity check. Acquires mutex (FUN_00737130), calls CFileReader__load_ansi_with_md5_check. On failure, gets error code, formats error string "%s (%d)", logs via FUN_0076dfa0 with source path "C:\\repositories\\RagnarokClient\\R..." at line 0x8c. Returns 1 on success, 0 on failure. |
| 0x0076B973 | 236 | CFileReader__LoadWithHashCheck | Loads a file with hash integrity check. Acquires mutex, calls CFileReader__load_ansi_with_hash_check with 3 params. On failure, gets error code, formats error string, logs via FUN_0076dfa0 at line 100 (0x64). Returns 1 on success, 0 on failure. |
| 0x0076BA60 | 228 | CFileReader__LoadBasic | Basic file load without integrity check. Acquires mutex, calls thunk_00401640 for reading. On failure, gets error code, formats error string, logs via FUN_0076dfa0 at line 0x42. Returns 1 on success, 0 on failure. |
| 0x00AE99D0 | 543 | CGrfMgr__create_and_add_entry | Creates a new GRF entry pair (0x148-byte timer manager + 0x40-byte sub-manager), links them into the 0x10-byte linked list at param_1. Initializes critical section, vtables. Calls FUN_00aebdb0 to process the new entry. Throws list_too_long if at max. |
| 0x00AE9BF0 | 43 | CGrfMgr__load_file | Loads a file, first trying disk (load_file_from_disk), then GRF archive (load_file_from_grf) if disk fails. |
| 0x00AE9FE0 | 255 | CGrfMgr__load_file_from_grf | Loads a file from a GRF archive. Iterates GRF entries in the linked list, calls FUN_00aeba30 to find the file. Allocates buffer via VirtualAlloc, extracts via FUN_00aeb710. Returns buffer or NULL. |
| 0x00AEA0E0 | 163 | CGrfMgr__file_exists | Checks if a file exists in GRF archives or on disk. If param_3==0, searches GRF entries first via FUN_00aeba30. Always checks disk via FindFirstFileA. Returns 1 if found, 0 if not. |
| 0x00AEA1F3 | 513 | CGrfMgr__find_best_grf_data | Iterates all GRF entries, extracts file listing data from each, and keeps the best (largest) version in a byte vector. If found, applies the data to all GRF entries via FUN_00aec9f0. |
| 0x00AEB710 | 798 | CGrfEntry__extract_file | Extracts a file from a GRF archive entry. Reads compressed data from the GRF file, then based on file flags: (1) encrypted+compressed: uses PacketCrypto__decrypt_and_verify, (2) DES encrypted: derives key from filename, uses CDesCipher, (3) DES+cycle encrypted: similar but with digit-count-based cycle parameter. Decompresses if needed via zlib. Uses scoped lock for thread safety. |
| 0x00AEBA30 | 167 | CGrfEntry__find_file_record | Binary searches the GRF file table (vector of 0x120-byte records at offsets +0x24/+0x28) for a file by name. Uses FUN_00aecee0/00aece80 as comparison functions. Copies the 0x120-byte record to param_3 if found. Returns 1 if found, 0 if not. |
| 0x00AEBAE0 | 280 | CGrfEntry__read_file_table_data | Reads file table data from a GRF archive. Handles 3 GRF format versions (0x100, 0x200, 0x300) with different header layouts. Reads compressed data, resizes the byte vector, copies data, and optionally extracts version info. |
| 0x00AEBC00 | 55 | CGrfEntry__reset_state | Resets GRF entry state. Sets end pointer = begin pointer for file table, zeroes fields at offsets +8 through +0x20, resets byte vector end to begin. |
| 0x00AEBDB0 | 667 | CGrfEntry__parse_header_and_load | Parses GRF archive header and loads file table. Reads magic bytes (0x2E offset), validates against two known signatures (XOR-encrypted). Extracts file count, offsets. Dispatches to version-specific file table parsers (v1/v2/v3). Resets state on failure. |
| 0x00AEC050 | 967 | CGrfEntry__parse_v1_file_table | Parses GRF v1 (0x100) file table. Reads raw file entries with DES decryption and nibble swapping. Each entry has: compressed size, uncompressed size, flags, filename. Builds 0x120-byte records in the file table vector. Sorts after loading. |
| 0x00AEC420 | 498 | CGrfEntry__parse_v2_file_table | Parses GRF v2 (0x200) file table. Reads 8-byte header (compressed/uncompressed sizes), decompresses with zlib, then parses entries sequentially. Each entry: null-terminated name + 0x11 bytes of metadata. Sorts after loading. |
| 0x00AEC620 | 509 | CGrfEntry__parse_v3_file_table | Parses GRF v3 (0x300) file table. Reads 12-byte header (compressed size, uncompressed size, entry count), decompresses, parses entries with null-terminated names + 0x16 bytes metadata (extra 4 bytes vs v2). Sorts after loading. |
| 0x00AEC820 | 451 | CGrfEntry__read_raw_file_table | Reads the raw file table data from a GRF archive. Handles v2 and v3 format differences. Reads compressed data, decompresses with zlib, extracts version info. Returns version byte (masked to low byte) or 0xFF on failure. |
| 0x00AECA50 | 74 | CMemMappedFile__close | Closes a memory-mapped file. UnmapViewOfFile if mapped, CloseHandle for mapping and file handles. Zeroes all handle pointers. |
| 0x00AECAA0 | 103 | CMemMappedFile__init | Initializes CMemMappedFile members. Gets system allocation granularity via GetSystemInfo, sets view size to 0x20000000 (512MB), computes alignment mask. Zeroes all file/mapping handles and state. |
| 0x00AECB10 | 151 | CMemMappedFile__open | Opens a file for memory-mapped reading. CreateFileA with read-only shared access, GetFileSizeEx, CreateFileMappingA with PAGE_READONLY. Returns 1 on success, 0 on failure. |
| 0x00AECBB0 | 425 | CMemMappedFile__read_at_offset | Reads data at a given file offset via memory-mapped view. Checks if offset falls within current mapped view; if not, unmaps and remaps. Aligns offset to allocation granularity. Falls back to ReadFile if mapping fails (halves view size on failure). Returns pointer into mapped view or read buffer. |
| 0x00AECDE0 | 21 | CGrfFileRecord__set_name | Sets the name of a GRF file record by calling FUN_00aecf90 with param_2. Returns this pointer. |
| 0x00AECE00 | 17 | CGrfFileRecord__set_empty_name | Sets the name of a GRF file record to an empty string (DAT_010d4ee8). Returns this pointer. |
| 0x00AECE20 | 85 | CGrfFileRecord__compare_names | Compares two GRF file record names byte-by-byte. First compares the initial dword, then does a byte-by-byte strcmp-like comparison. Returns 1 if equal, 0 if different. |
| 0x00AECE80 | 85 | CGrfFileRecord__compare_not_equal | Compares two GRF file records for inequality. First compares hash dwords, then does byte-by-byte name comparison. Returns non-zero if not equal (for use as binary search comparator with 'not less' semantics). |
| 0x00AECEE0 | 83 | CGrfFileRecord__compare_less_than | Less-than comparison for GRF file records. First compares hash dwords, then byte-by-byte name comparison. Returns 1 if this < param_2 (for binary search / sort). |
| 0x00AECF40 | 78 | CGrfFileRecord__compute_hash | Computes DJB2 hash (seed=0x1505, multiply by 33) of the file record name string. Stores hash in the first dword (offset 0) of the record. |
| 0x00AECF90 | 101 | CGrfFileRecord__set_name_and_hash | Sets the file record name from param_2. Copies string to offset +4, lowercases it via _strlwr, then computes and stores DJB2 hash at offset 0. |
| 0x00AEDA40 | 415 | CGrfEntry__ctor | CGrfEntry constructor. Allocates tree sentinel (0x18 bytes), allocates secondary tree sentinel (0x40 bytes), zeroes all state fields (file handles, sizes, offsets, vectors). Initializes critical section for thread safety. |
| 0x00AEE070 | 381 | CResourceMgr__dtor | Destructor for CResourceMgr. For each GRF tree: iterates all entries calling their cleanup method (+0x18) and deleting objects (+0x0), then clears the tree. Deletes the CriticalSection, frees vectors of trees, the name map at 0x44, additional vectors, and the root tree. |
| 0x00AEE310 | 580 | CResourceMgr__report_load_failure | Reports a resource file loading failure. Checks if the file has a non-.xxx extension, then enters critical section, checks if the path is already in the failure tree (case-insensitive compare). If new failure, inserts a new 0x28-byte tree node with the path. Dispatches three chat messages: 'Resource File Loading fail', the resource key, and the file path. Limit of 0x6666666 entries. |
| 0x00AEE5E0 | 196 | CResourceMgr__lookup_resource_by_name | Looks up a resource by name string in the tree at field[0]. Uses std::tree lower_bound with string comparison. Returns the resource value at node+0x14 if found, or 0xffffffff with an error sprintf if not found (ResourceError: %s is Undefined). |
| 0x00AEE6B0 | 182 | CResourceMgr__find_in_grf_by_index | Finds a resource in a specific GRF file by index. Sets up the GRF file record name, performs tree lower_bound search in the GRF tree at vector[param_2]. Returns the resource value at node+0x14 if found, 0 if not found. |
| 0x00AEE770 | 1350 | CResourceMgr__load_resource_by_path | Loads a resource by raw path string (int param). Enters critical section, normalizes path to lowercase, looks up resource type by extension. If found in GRF tree cache, updates access time and returns. Otherwise loads from GRF file, sets name/hash/type/access time, inserts into tree. On load failure, checks for map path and reports error. |
| 0x00AEECC0 | 1724 | CResourceMgr__load_resource_by_string | Loads a resource by STL string path. Same logic as load_resource_by_path but accepts std::string. Enters critical section, normalizes, looks up type, checks cache, loads from GRF, inserts into tree, reports failures. |
| 0x00AEF3A0 | 341 | CResourceMgr__get_path_without_extension | Extracts the path without the file extension. Appends '.xxx' suffix, calls resolve_alias_path, then finds '.xxx' via strstr and returns the substring before it. |
| 0x00AEF500 | 714 | CResourceMgr__resolve_alias_path | Resolves an alias path by looking up in the alias map at offset 0x44. If the path is found, returns the mapped alternative path. If not found, tries stripping '@xxx' version suffixes (searching backwards for '@' then removing 3 chars) and looking up again. Returns the resolved path string. |
| 0x00AEF7D0 | 364 | CResourceMgr__resource_exists_by_cstr | Checks if a resource exists by C string path. Normalizes to lowercase, looks up resource type, builds full path, checks GRF tree cache (updating access time if found). Falls back to CFileSystem__file_exists_check for disk files. Returns 1 if exists, 0 otherwise. |
| 0x00AEF940 | 400 | CResourceMgr__resource_exists_by_string | Checks if a resource exists by STL string path. Same logic as resource_exists_by_cstr but accepts std::string parameter. Normalizes, checks GRF cache, falls back to filesystem check. |
| 0x00AEFAE0 | 528 | CResourceMgr__build_full_path | Builds a full resource path by combining a filename (param_2) with a base path prefix (param_3). If the filename already starts with the prefix (strncmp match), returns the filename as-is. Otherwise concatenates prefix + filename via STL string concatenation. |
| 0x00AEFDB0 | 35 | CResourceMgr__flush_pending_resources | Flushes pending resource objects. Iterates the pending list between offsets 0x90 and 0x94, calling each resource's virtual method at vtable+8 (likely a finalize/commit operation). |
| 0x00AEFDE0 | 111 | CResourceMgr__dump_resource_names_to_file | Opens a file and writes all resource names from the tree containers. Iterates through the vector of trees at offset 0x20, walking each tree's nodes and printing the string at node+0x14 using fprintf. |
| 0x00AEFE50 | 1626 | CResourceMgr__load_res_name_table | Loads ResNameTable.txt, reads the entire file into memory, parses line-by-line. Lines starting with '#' separate key/value pairs which are inserted into the resource tree (offset 0x44). Uses CFileStream to open/read/close the file. |
| 0x00AF04B0 | 456 | CResourceMgr__add_resource_entry | Adds a resource entry to the manager. Looks up the name in the tree using lower_bound; if not found, allocates a 0x18-byte node and inserts it. Then appends param_4 and param_3 to vectors at offsets 0x18 and 0x0C respectively. Adjusts the tree vector at offset 0x20 to match the new size. |
| 0x00AF0680 | 198 | CResourceMgr__release_all_unused_resources | Releases all unused resources. Resets the active list pointer (offset 0x94 = 0x90), then iterates all resource trees at offset 0x20. For each tree node, calls the release vtable method at vtable+0x18, then destructs the resource object via vtable[0]. Finally destroys and reinitializes each tree. |
| 0x00AF0780 | 182 | CResourceMgr__remove_resource_by_name | Removes a resource from the manager by name. Searches the active list (offset 0x90-0x94) for the resource, removes it from the active list via memcpy. Then looks up the resource in the appropriate tree (using field at offset 0x0C of the resource), calls its release method (vtable+0x18), destructs it, and erases the node from the tree. |
| 0x00AF0840 | 198 | CResourceMgr__release_all_unused_resources_00af0840 | Identical to CResourceMgr__release_all_unused_resources at 00af0680. Releases all unused resources by resetting active list, iterating all trees, calling release+destruct on each node, then reinitializing each tree. Likely a duplicate or variant for a different call context. |
| 0x00AF0910 | 254 | CResourceMgr__expire_timed_out_resources | Expires resources that have timed out. Gets current time via timeGetTime(), compares elapsed time against each resource's timeout. Resources with refcount==0 (field+4) and elapsed time > threshold (field+8) are removed from the active list, released via vtable, destructed, and erased from the tree. |
| 0x00AF0A10 | 206 | CResourceMgr__release_resources_by_type | Releases all unused resources of a specific type. Calls CResourceMgr__lookup_resource_by_name to get the type index, then iterates that type's tree. Resources with refcount==0 (field+4) are removed from the active list, released via vtable, destructed, and erased from the tree. |
| 0x00AF0AE0 | 246 | CResourceMgr__release_all_unreferenced | Releases all unreferenced resources regardless of timeout. Similar to expire_timed_out but does NOT check elapsed time, only checks refcount==0 (field+4). Calls timeGetTime() but doesn't use the result for filtering. Iterates all trees and removes/destructs unreferenced resources. |
| 0x00AF1620 | 587 | CResourceMgr__get_instance | Singleton accessor for the global CResourceMgr instance at DAT_016d56c8. On first call, allocates and initializes the entire resource manager structure: tree sentinel, vectors for resource types/names/active list, and a CriticalSection for thread safety. Registers an atexit cleanup handler. Returns pointer to the singleton. |
| 0x00C83C20 | 173 | OLEStorage__ctor_with_file | OLEStorage constructor with file path parameter. Initializes CResourceManager (memory I/O buffer), CDocumentStream, zeroes internal state fields (0x488-0x49C), then opens the specified file via OLEStorage__open_file_ansi. Object size ~0x4A0 bytes. |
| 0x00C83CD0 | 157 | OLEStorage__ctor_default | OLEStorage default constructor. Initializes CResourceManager (memory I/O buffer), CDocumentStream, zeroes internal state fields (0x488-0x49C). No file is opened. Object size ~0x4A0 bytes. |
| 0x00C8BFE0 | 1186 | OLEStorage__add_stream_node_char | Adds a new stream node to the OLE storage container by char name. Searches existing nodes for duplicate names, creates CBaseStreamNode + CDocumentStream + CIOStreamNode. If param_3==-1, appends at end; otherwise inserts at specified position. Sets the char string pair name and clears flag bit 0x200. |
| 0x00C8C490 | 1202 | OLEStorage__add_stream_node_wchar | Adds a new stream node to the OLE storage container by wchar name. Identical to char variant but checks wchar string at offset 0x30 (flag bit 0x01 set). Creates CBaseStreamNode + CDocumentStream + CIOStreamNode. Supports insert-at-position or append modes. |
| 0x00C8C950 | 210 | ExcelWorkbook__compute_sheet_offsets | Computes the byte offset for each sheet in an Excel workbook. Starts from the total workbook header size, then iterates each sheet (0x3C stride at +0x3c8, data at +0x488 with 0x124 stride). For each sheet, sums 6 virtual function calls to get sub-section sizes, stores cumulative offset at sheet+0x28. |
| 0x00C8CA30 | 845 | ExcelWorkbook__compute_stream_offsets | Computes cumulative byte offsets for all streams in an Excel workbook. Iterates through IO stream nodes (0x124 stride), computing sizes via virtual dispatch. For each sheet's rows, calls ExcelCell__dispatch_compute_size for each cell record. Stores computed offsets at stream+0x70 entries and row data offsets at sheet+0x40/0x44. |
| 0x00C8CD80 | 676 | ExcelWorkbook__compute_sst_offsets | Computes SST (Shared String Table) offsets and pagination for Excel workbook serialization. Iterates records at 0x44, 0x40, 0x3c, and 0x3c strides, accumulating sizes. Divides total strings into groups of 10, resizing offset/size vectors. Handles BIFF record continuation splits at 0x2020 bytes. |
| 0x00C8D030 | 217 | ExcelWorkbook__compute_offsets_and_write | Computes sheet offsets (same as compute_sheet_offsets) then calls the write function. Iterates all sheets, calculates cumulative byte positions, then invokes the sheet data writer at 00c8ca30. |
| 0x00C8D120 | 390 | ExcelWorkbook__get_cell_or_expand | Gets a cell pointer for (row, col) in the workbook grid, expanding the grid if needed. Returns pointer to a 0x28-byte cell struct. If col >= current col count, expands all rows to the new column count. If row >= current row count, creates new rows. Bounds: row < 0x10000, col < 0x100. Returns 0 if out of bounds. |
| 0x00C8D560 | 100 | ExcelWorkbook__reset_stream_state | Resets the workbook's stream reader state. Calls stream lib function, clears/sets basic_ios state, resets read position (this+4 = this+0), clears parse counters at +0xD4/+0xD8, sets buffer size to 0x200. Returns 1 if the name table at +0x74 is empty, 0 otherwise. |
| 0x00C8D5D0 | 243 | ExcelWorkbook__reset_full_state | Full reset of workbook state. Copies backup positions (+0x2F8 to +0x2FC, +0x304 to +0x308), frees all sheet data objects (0x7C each) from vector at +0x318, resets the vector, recursively destroys the tree root at +0x310, resets stream reader state, clears read position, and resets buffer to 0x200. |
| 0x00C8DA70 | 157 | OLEStorage__open_file_unicode | Opens an OLE compound document file given a Unicode filename. Converts the wide string to multibyte, opens the file via basic_filebuf, sets stream state on failure, clears state, then opens the OLE stream. Returns the result of OLEStorage__open_stream_unicode. |
| 0x00C8DB10 | 103 | OLEStorage__open_file_ansi_00c8db10 | Opens an OLE compound document file given an ANSI filename. Converts the char* to a wchar_t* via mbstowcs, then delegates to the Unicode version (FUN_00c8db80). Frees the temporary wide string buffer. |
| 0x00C8DB80 | 662 | OLEStorage__open_and_init | Opens an OLE compound document file (Unicode path) and fully initializes the storage. Opens the file stream, reads the OLE compound header, rebuilds sector allocation tables (FAT), updates the root directory entry, initializes the FAT sector array (0x80 entries), writes FAT sectors, creates a Root Entry directory entry, and sets up the initial stream tracking structure. Returns 1 on success. |
| 0x00C8E150 | 329 | OLEStorage__collect_chain_and_compute_size | Follows a FAT sector chain starting from param_2, collecting all sector indices into a vector. If param_3 is false, follows the regular FAT chain (offset 0x304); if true, follows the mini-FAT chain (offset 0x2F8). Returns the total byte size = sector_count * sector_size (regular=0x2F4, mini=0x2F0). |
| 0x00C8E870 | 287 | ExcelWorkbook__compute_total_size | Computes total serialized byte size for the entire Excel workbook. Sums sizes from the global records, multiple record arrays (strides 0x44, 0x40, 0x4C, 0x3C), plus individual record objects at specific offsets. Each record's size is obtained via virtual method at vtable+0x10. |
| 0x00C8E990 | 75 | ExcelWorkbook__compute_all_streams_size | Computes the total size of all streams in the workbook by summing sizes from 6 different record/stream objects via their virtual size methods, including the sheet data size from ExcelWorkbook__compute_all_sheets_size. |
| 0x00C8E9E0 | 791 | OLEStorage__remove_sectors_and_reindex | Removes specified sectors from the OLE FAT and reindexes all remaining sector references. Takes a sorted array of sector indices to remove. Updates directory entry start sectors, mini-FAT chain entries, and all FAT chain pointers to account for the removed sectors. Sorts the removal list, then shifts remaining entries down and adjusts all indices that reference sectors after the removed ones. |
| 0x00C8ED90 | 102 | OLEStorage__open_stream_ansi_00c8ed90 | Opens an OLE stream by ANSI name. Converts the char* to a wchar_t* via mbstowcs, delegates to the Unicode version (FUN_00c8ee00), then frees the wide string buffer. Returns the result of the Unicode open. |
| 0x00C8EE00 | 303 | OLEStorage__open_stream_by_path | Opens an OLE stream by traversing the directory tree using a path. Pushes the current directory onto a stack, finds the matching directory entry, then recursively processes children: type 0x01 (storage) recurses, type 0x02 (stream) reads size. Pops the directory stack when done. Returns 1 on success, 0xFFFFFFFE if not found. |
| 0x00C8EF30 | 187 | OLEStorage__remove_directory_entry | Removes a directory entry from the OLE storage. Decrements indices in the tree that are above the removed entry's index, frees the directory entry object, shifts the directory entry array down, then removes the entry from the parent's child list and rebalances the tree. |
| 0x00C8EFF0 | 1147 | OLEStorage__remove_stream_by_index | Removes a stream from the OLE storage by its index in the stream arrays. Shifts entries in three parallel arrays (stride 0x3C for names, stride 0x124 for stream nodes, stride 0x1C for associated data) down by one to fill the gap. Copies both ANSI and Unicode name strings, clones sub-vectors, and calls destructors on the removed entry. Returns 1 on success, 0 if index out of bounds. |
| 0x00C8F470 | 158 | OLEStorage__find_and_remove_stream_by_ansi_name | Searches for a stream by ANSI name in the stream name array (stride 0x3C, byte-mode entries). Compares strings and if found, delegates to remove_stream_by_index to delete it. Returns the result of the removal. |
| 0x00C8F510 | 164 | OLEStorage__find_and_remove_stream_by_unicode_name | Searches for a stream by Unicode name in the stream name array (stride 0x124, wide-char entries). Compares wide strings and if found, delegates to remove_stream_by_index to delete it. Returns the result of the removal. |
| 0x00C8F5C0 | 604 | OLEStorage__list_child_stream_names | Lists child stream names under the current directory. Pushes the current directory, optionally navigates to a subdirectory, then iterates over all child entries collecting their wide-char names into a vector of wstring. Pops the directory stack when done. Returns 1 on success. |
| 0x00C8FB60 | 715 | OLEStorage__allocate_new_sector | Allocates a new sector in the OLE FAT. Clears the FAT data, then depending on whether it is a regular sector (param_2=0) or a mini-sector (param_2!=0), finds a free slot (0xFFFFFFFF in the appropriate table) and inserts a new sector. Updates sector counts, adjusts indices after the insert, and extends the FAT chain with a ENDOFCHAIN (0xFFFFFFFD) marker. |
| 0x00C8FE30 | 105 | OLEStorage__get_stream_size_ansi | Gets the size of an OLE stream by ANSI name. Converts char* to wchar_t* via mbstowcs, calls the Unicode version, then frees the wide buffer. Returns the result. |
| 0x00C8FEA0 | 115 | OLEStorage__get_stream_size_unicode | Gets the size of an OLE stream by Unicode name. Compares the name against a root entry marker; if it matches, uses the root directory entry. Otherwise, searches the directory tree for the named entry. Writes the size (from offset 0x78 in the directory entry) into param_3. Returns 1 on success, 0xFFFFFFFC if not found. |
| 0x00C8FF20 | 224 | OLEStorage__find_directory_entry_by_id | Recursively searches the OLE directory tree for an entry with the given ID (param_2). Uses a stack-based depth-first search, pushing the current directory and recursing into children. Returns the matching directory tree node, or 0 if not found. |
| 0x00C90080 | 272 | OLEStorage__navigate_to_path | Navigates to a directory entry by path. Pushes the current directory, handles absolute paths (starting with backslash) by resetting to root. Tokenizes the path, navigates subdirectories, then finds the final child by name. Restores the original directory on completion. Returns the found directory node or 0 if not found. |
| 0x00C90190 | 1563 | OLEStorage__remove_sectors_and_compact_FAT | Removes specified sectors and compacts the FAT. For regular sectors (param_3=0): reads stream chain data, removes specified sectors from the data, rewrites the chain, updates indices and directory entry sizes. For mini-sectors (param_3=1): copies the removal list, calls remove_sectors_and_reindex, then deletes records from the flat file. Both paths then compact unused trailing sectors from the FAT/mini-FAT, recursively calling themselves until no more sectors can be freed. |
| 0x00C908E0 | 39 | OLEStorage__get_stream_ansi_name | Returns the ANSI name pointer for a stream at the given index. Checks if the stream is byte-mode (flag bit 0 == 0 at offset 0x38 in the 0x3C-stride array). Returns the name pointer at offset 0x34, or 0 if the stream is Unicode-mode. |
| 0x00C90930 | 151 | OLEStorage__collect_sector_chain | Collects a full sector chain into a vector starting from sector param_2. If param_4 is false, follows the regular FAT chain (offset 0x304); if true, follows the mini-FAT chain (offset 0x2F8). Pushes each sector index until ENDOFCHAIN (-2) is reached. |
| 0x00C90A50 | 226 | OLEStorage__allocate_free_sector_in_chain | Finds a free sector slot in the regular or mini FAT chain and marks it as ENDOFCHAIN (-2). For regular sectors (param_2=0), searches the FAT at offset 0x304 for a -1 entry; if none found, allocates a new sector first. For mini-sectors (param_2=1), searches the mini-FAT at offset 0x2F8 similarly. |
| 0x00C90BE0 | 58 | OLEStorage__copy_stream_ansi_name | Copies the ANSI name of a stream at the given index into the output buffer. Checks that the stream is byte-mode (flag bit 0 == 0). Returns 1 on success, 0 if the stream is Unicode-mode. |
| 0x00C90C20 | 61 | OLEStorage__copy_stream_unicode_name | Copies the Unicode name of a stream at the given index into the output buffer. Checks that the stream is Unicode-mode (flag bit 0 == 1). Returns 1 on success, 0 if the stream is byte-mode. |
| 0x00C91060 | 567 | OLEStorage__adjust_indices_after_insert | Adjusts various indices in the OLE storage structure after rows are inserted. Updates column indices at +0x13c (109 entries), special indices at +0x120/+0x12c/+0x134, dynamic index array at +0x2f8, and directory entry indices at +0x318. Increments indices that are >= insertion points. |
| 0x00C91380 | 126 | OLEStorage__insert_row_at_index | Inserts a row at the given index in the OLE storage. Shifts existing rows down by calling swap operations. Uses flag at +0xc bit 1 to check if storage is writable. Returns 1 on success. |
| 0x00C91400 | 357 | OLEStorage__build_directory_tree_node | Recursively builds a directory tree node for OLE compound document. Allocates 0x18-byte node, links parent/child references (offsets +0x44, +0x48, +0x4c), inserts children sorted by index at +8. Calls OLETreeNode__rebalance to finalize node. |
| 0x00C915B0 | 48 | OLEStorage__set_sector_index | Sets a sector index value in either the mini-FAT (at +0x2f8, when param_4!=0) or regular FAT (at +0x304, when param_4==0). Index = param_2, value = param_3. |
| 0x00C915E0 | 557 | OLEStorage__open_file_ansi | Opens an OLE compound document file from ANSI path. Converts filename to wide string via mbstowcs, opens the stream, creates CDocumentStream, reads directory looking for 'Workbook' stream (Excel format). Copies filename to buffer at +0x4a0. |
| 0x00C91810 | 1132 | OLEStorage__read_sector_allocation_tables | Reads FAT (File Allocation Table) sectors, DIFAT sectors, and mini-FAT sectors from an OLE compound document stream. Reads raw bytes from seekable stream, packs 4 bytes into uint32 entries. Uses three separate sector tables at +0xbe/+0xc1 offsets. Sectors are 512 bytes each (0x200). |
| 0x00C91C80 | 122 | OLEStorage__validate_and_init_header | Validates OLE compound document header by checking magic bytes (0xE011CFD0 and 0xE11AB1A1), reads sector size from +0xbc, initializes sector count at +0x39 from file size / sector size. |
| 0x00C91D00 | 411 | OLEStorage__read_directory_entries | Reads OLE directory entries from the compound document. Allocates buffer for directory stream data, reads sectors via FAT chain, creates OLEDirectoryEntry objects (0x7c bytes each, 4 per 512-byte sector). Builds directory tree starting from root entry's child index at +0x4c. |
| 0x00C91EA0 | 102 | OLEStorage__find_stream_by_ansi_name | Finds an OLE stream by ANSI name. Converts the ANSI string to wide string via mbstowcs, then delegates to OLEStorage__find_stream_by_unicode_name. Frees the wide string buffer after. |
| 0x00C91F10 | 226 | OLEStorage__find_stream_by_unicode_name | Finds/opens an OLE stream by Unicode name. Pushes current directory entry onto stack, creates new OLEDirectoryEntry (0x7c bytes, type=1=storage), delegates to insert_directory_entry, then restores directory state and rebuilds FAT chain. |
| 0x00C92000 | 300 | OLEStorage__create_stream_by_ansi_name | Creates an OLE storage entry by ANSI name. Converts ANSI to wide string via mbstowcs, creates OLEDirectoryEntry (type=2=stream), delegates to insert_directory_entry. Restores directory state and rebuilds FAT chain. |
| 0x00C92130 | 226 | OLEStorage__create_stream_by_unicode_name | Creates an OLE storage entry by Unicode name. Creates OLEDirectoryEntry (type=2=stream), delegates to insert_directory_entry. Restores directory state and rebuilds FAT chain. |
| 0x00C92220 | 656 | OLEStorage__insert_directory_entry | Inserts a new directory entry into the OLE directory tree. Parses path (backslash = root), tokenizes name, finds sorted insertion position by comparing Unicode names (shorter names first, then lexicographic). Updates tree indices and rebuilds tree node linkage. |
| 0x00C924B0 | 124 | OLEStorage__move_row | Moves a row from one index to another by repeated adjacent swaps. Direction depends on whether src < dst or src > dst. Returns 1 on success, 0 if storage not writable or indices out of range. |
| 0x00C92530 | 855 | OLEStorage__reset_and_add_sheets | Resets OLE storage stream nodes and adds worksheet sheets. Clears/resizes 4 types of stream node vectors (0x44, 0x40, 0x4c, 0x3c stride). Then adds additional sheets by name 'Sheet_N'. Used when opening Excel workbook with multiple sheets. |
| 0x00C92890 | 286 | OLEStorage__open_stream_unicode | Opens an OLE stream by Unicode filename. Converts wide name to ANSI via wcstombs, calls low-level file open, then seeks to end to determine file size, calculates sector count. Returns 1 on success. |
| 0x00C929B0 | 106 | OLEStorage__open_compound_document_ansi | Opens an OLE compound document by ANSI filename. Converts to wide string via mbstowcs, delegates to OLEStorage__open_compound_document. Frees the wide string after. |
| 0x00C92A20 | 656 | OLEStorage__open_compound_document | Opens and initializes an OLE compound document from a Unicode file path. Clears existing data, opens stream, validates OLE header (magic 0xE011CFD0/0xE11AB1A1), reads FAT, reads directory entries, builds directory tree. Core initialization function for OLE file reading. |
| 0x00C92CB0 | 231 | OLEStorage__read_stream_to_ansi_string | Reads current OLE stream content and converts from Unicode to ANSI. Calls read_stream_data to get wide char buffer, then wcstombs to convert. Frees the wide buffer with proper alignment handling. |
| 0x00C92DA0 | 537 | OLEStorage__read_stream_data_unicode | Reads the current OLE stream data as Unicode wide chars into a vector buffer. Returns 1 on success. |
| 0x00C92FC0 | 130 | OLEStorage__get_current_path_ansi | Gets the current OLE directory path as an ANSI string. Allocates wide buffer, calls build_full_path to construct the Unicode path, converts to ANSI via wcstombs, frees the wide buffer. Returns 1 on success. |
| 0x00C93050 | 662 | OLEStorage__build_full_path | Builds full OLE path by traversing parent directory entries from current to root. Prepends backslash separators. Pushes/pops directory stack at +0x328. Removes the initial root entry name (first 0xb chars) from the result. |
| 0x00C935E0 | 304 | BIFFRecord__parse_record_12byte_header | Parses a 12-byte BIFF record with header. Reads: 2-byte record type (+0x28), 2-byte field (+0x2a), 1-byte field (+0x2c), 1-byte field (+0x2d), 2-byte field (+0x2e), 4-byte size (+0x30). Then reads variable data into buffer and calls virtual handler at vtable+0x10. |
| 0x00C93710 | 244 | BIFFRecord__parse_record_16byte | Parses a 16-byte BIFF record. Reads: 2-byte record type, 2-byte field, 2-byte field, 2-byte field, 4-byte field, 4-byte field. Calls virtual handler at vtable+0x10. |
| 0x00C93810 | 933 | ExcelWorkbook__parse_BIFF_records | Main BIFF record parser loop for Excel workbook. Reads 2-byte record IDs (0x809 = BOF). Dispatches by sub-record type: type 5 calls FUN_00c96a90 (formula parser), type 0x10 creates CDocumentStream and parses sheet data via FUN_00c96eb0, others use generic record skip. Loops until end of data. |
| 0x00C93BF0 | 137 | BIFFRecord__parse_record_6byte | Parses a 6-byte BIFF record. Reads: 2-byte record type, 2-byte field, 2-byte field. Calls virtual handler at vtable+0x10. |
| 0x00C93C80 | 126 | OLEStorage__seek_and_read_sector | Seeks to a specific sector in the OLE file and reads its data. Sector offset = sector_size * param_2. Uses istream seekg + read. Returns 1 if read succeeded (no error flags). |
| 0x00C93D00 | 159 | BIFFRecord__parse_record_8byte | Parses an 8-byte BIFF record. Reads: 2-byte record type, 2-byte field, 2-byte field, 1-byte field, 1-byte field. Calls virtual handler at vtable+0x10. |
| 0x00C93DA0 | 103 | BIFFRecord__parse_record_with_string_data | Parses a BIFF record with a 4-byte uint32 field, two 1-byte fields, then variable-length string data via FUN_00c96480. Calls virtual handler at vtable+0x10. |
| 0x00C93E10 | 198 | ExcelWorkbook__dispatch_cell_record | Dispatches BIFF cell record types to their respective handlers. Record ID 6=Formula(0x6), 0xBD=MulRk, 0xBE=MulBlank, 0xFD=LabelSST, 0x201=Blank, 0x203=Number, 0x205=BoolErr, 0x27E=RK. Each type has its own vtable handler at specific offsets. |
| 0x00C94180 | 162 | BIFFRecord__parse_record_with_uint16_array | Parses a BIFF record with a 4-byte uint32 field followed by a variable-length array of uint16 values. Array count = (record_size - 4) / 2. Calls virtual handler at vtable+0x10. |
| 0x00C94230 | 200 | BIFFRecord__parse_record_14byte | Parses a 14-byte BIFF record. Reads: 4-byte uint32, 4-byte uint32, 2-byte uint16, 2-byte uint16, 2-byte uint16. Calls virtual handler at vtable+0x10. |
| 0x00C94300 | 311 | BIFFRecord__parse_record_with_uint32_array | Parses a BIFF record with a 2-byte header followed by variable-length array of (uint32, uint16, uint16) triples. Array count = (record_size - 2) / 8. Calls virtual handler at vtable+0x10. |
| 0x00C94440 | 269 | BIFFRecord__parse_record_14byte_with_string | Parses a BIFF record with 5 uint16 fields, 2 byte fields, then variable-length string data via FUN_00c96480. Calls virtual handler at vtable+0x10. |
| 0x00C94550 | 655 | BIFFRecord__parse_formula_record | Parses a BIFF formula record (type 6/0x206). Reads header: 2-byte row, 2-byte col, 2-byte XF index, 8-byte result value, 2-byte flags, 4-byte field, then variable formula data. After formula, dispatches sub-records: 0x221=Array, 0x36=Continue, 0xBC=ShrFmla, 0x4BC=ShrFmla2. Also handles 0x207=String record. |
| 0x00C94B20 | 288 | BIFFRecord__parse_DBCELL_record | Parses a BIFF DBCELL record. Reads: 4-byte row offset, 4-byte field, 4-byte first row, 4-byte field. Calculates bitfield array size from row range, fills uint32 array from remaining record data. Calls virtual handler. |
| 0x00C94C40 | 178 | BIFFRecord__parse_record_10byte | Parses a 10-byte BIFF record. Reads: 2-byte record type, 2-byte field, 2-byte field, 4-byte uint32. Calls virtual handler at vtable+0x10. |
| 0x00C94DD0 | 292 | BIFFRecord__parse_MulBlank_record | Parses BIFF MulBlank record (0xBE). Reads row, first column, last column from header. Contains array of XF indices for blank cells spanning first_col to last_col. |
| 0x00C94F00 | 324 | BIFFRecord__parse_MulRk_record | Parses BIFF MulRk record (0xBD). Reads row, first column, last column. Contains array of (uint16 XF, uint32 RK value) pairs for multiple cells in one row. |
| 0x00C95050 | 275 | BIFFRecord__parse_Number_record | Parses BIFF Number record (0x203). Reads row, column, XF index, then 8-byte IEEE 754 double value (read as byte-swapped uint64). |
| 0x00C953D0 | 178 | BIFFRecord__parse_RK_record | Parses BIFF RK record (0x27E). Reads row (2 bytes), column (2 bytes), XF index (2 bytes), and 4-byte RK value (encoded int or float). Calls virtual handler. |
| 0x00C95490 | 415 | BIFFRecord__read_record_header_and_data | Reads BIFF record header (2-byte type, 2-byte size) and copies record data into internal buffer. Handles CONTINUE records (type 0x3C) by appending their data to the previous record. Returns total bytes consumed including all CONTINUE records. |
| 0x00C95630 | 281 | BIFFRecord__parse_record_16byte_variant | Parses a 16-byte BIFF record variant. Reads 3 uint16 fields, 3 more uint16 fields, and 1 uint32 field. Calls virtual handler at vtable+0x10. |
| 0x00C95750 | 1493 | ExcelWorkbook__parse_sheet_records | Parses all records in a BIFF sheet stream. Loops reading record IDs: cell records (0x6, 0xBD, 0xBE, 0xFD, 0x201, 0x203, 0x205, 0x27E) are stored in a vector of CResourceEntry (0x2F8 bytes each). Record 0xD7 terminates. Record 0x208 creates CStreamNodeType208 objects. Other records are skipped. Pre-allocates 1000 entries and grows by 1000. |
| 0x00C96260 | 272 | BIFFRecord__parse_BoolErr_record | Parses BIFF BoolErr record (0x205). Header: 2-byte row, 2-byte col, 1-byte bool/error flag, 1-byte type, 2-byte XF index. Variable data follows header. Calls virtual handler. |
| 0x00C96370 | 272 | BIFFRecord__parse_Blank_record | Parses BIFF Blank record (0x201). Same structure as BoolErr: 2-byte row, 2-byte col, 1-byte flags, 1-byte type, 2-byte XF index, variable data. Calls virtual handler. |
| 0x00C96590 | 115 | BIFFRecord__parse_uint16_array_raw | Reads a raw array of uint16 values from a BIFF record. Array size = record data size. Resizes output buffer and reads each uint16 from little-endian bytes. Calls virtual handler. |
| 0x00C96610 | 130 | BIFFRecord__parse_string_or_byte_pair | Parses a BIFF record that contains either a string or a byte pair. If the 2-byte type field is negative (>=0x8000), reads 2 raw bytes; otherwise parses a BIFF string. Calls virtual handler. |
| 0x00C966A0 | 299 | BIFFRecord__parse_Window2_record | Parses BIFF Window2 record. Reads 16 bytes: 2-byte type, 2-byte col, 1-byte flags, 1-byte type byte, 2-byte field, 2-byte field, 2-byte field, 2-byte field, 2-byte field. Calls virtual handler. |
| 0x00C967D0 | 357 | BIFFRecord__parse_record_18byte | Parses an 18-byte BIFF record. Reads 4 uint16 fields, then 4 more uint16 fields, then 1 uint16 field. Calls virtual handler. |
| 0x00C96940 | 322 | BIFFRecord__parse_record_18byte_with_uint32 | Parses an 18-byte BIFF record variant with uint32 at end. Reads 4 uint16 fields, 2 more uint16 fields, 1 uint16 field, then 1 uint32 field. Calls virtual handler. |
| 0x00C96A90 | 1041 | ExcelWorkbook__parse_global_records | Parses BIFF global (workbook) records until EOF (record 0x0A). Dispatches known types: 0x31=Font (CStreamNodeWithFont), 0x3D=Window1, 0x85=BoundSheet (CBaseStreamNode), 0xE0=XF (CStreamNodeTypeE0), 0xFC=SST, 0x293=Style (CStreamNodeType293), 0x809=BOF. Unknown records are skipped via read_record_header_and_data. |
| 0x00C96EB0 | 885 | ExcelWorkbook__parse_workbook_stream | Parses BIFF workbook stream records until EOF (0x0A). Dispatches: 0x200=Dimensions, 0x208=Row (creates CStreamNodeD7Container, recurses into parse_sheet_records), 0x20B=Index, 0x23E=Window2, 0x809=BOF. Row containers (0x208) are stored in a vector (0x50 stride), pre-allocated to 1000. Unknown records are skipped. |
| 0x00C97230 | 278 | BIFFRecord__parse_XF_record | Parses BIFF XF (Extended Format) record. Reads: 2-byte row, 2-byte col, 2-byte XF, 2 bytes, 2 bytes, 2 bytes, uint32, uint32, 2-byte field. 22 bytes total. Calls virtual handler. |
| 0x00C97350 | 76 | OLEStorage__read_uint16_and_uint32 | Reads a uint16 and uint32 from a raw buffer into the object. Used by OLE stream parsing to read small header fields. |
| 0x00C973A0 | 639 | OLEStorage__read_stream_chain_data | Reads data from an OLE stream by following the FAT/mini-FAT chain. If param_4=0 (mini-stream), follows mini-FAT at +0x304, reads mini-sectors from root directory entry data. If param_4=1 (regular), follows regular FAT at +0x2f8, seeks and reads each sector directly. Returns total bytes read. |
| 0x00C97620 | 143 | OLEStorage__read_named_stream_ansi | Reads a named stream from OLE storage using ANSI name. Converts name to wide string, finds the stream directory entry, resizes buffer, reads stream content. Returns status code. |
| 0x00C976B0 | 105 | OLEStorage__read_stream_content_ansi | Reads stream content by ANSI name. Converts to wide string via mbstowcs, calls read_stream_by_name, frees wide string. Returns status code. |
| 0x00C97720 | 60 | OLEStorage__find_and_read_stream | Finds a named stream in the OLE storage, resizes the buffer, and reads its content. Wrapper that combines find + resize + read operations. |
| 0x00C97760 | 306 | OLEStorage__read_stream_by_name | Reads an OLE stream by Unicode name into output buffer. If name matches root ('\\'), reads from root directory entry. Otherwise finds the stream by name, determines if mini-stream (size<0x1000) or regular, reads the FAT chain data, copies to output. |
| 0x00C978F0 | 33 | BIFFRecord__compute_total_size_with_continue | Computes total record size including CONTINUE records. Calls virtual size method at vtable+0xc, adds 4 (header) + continues*4 for CONTINUE record overhead (every 0x2020 bytes). |
| 0x00C97920 | 16 | BIFFRecord__compute_total_size_simple | Computes simple total record size (no CONTINUE overhead). Calls virtual size method at vtable+0xc, adds 4 for the record header. |
| 0x00C97AE0 | 248 | ExcelWorkbook__compute_all_sheets_size | Computes total size for all Excel sheets (CStreamNodeD7Container array, 0x50 stride). For each sheet, sums sizes from CStreamNodeType208 objects (0x38 stride), cell records (0x2F8 stride via dispatch_compute_size), and the EOF marker. |
| 0x00C97BE0 | 33 | BIFFRecord__compute_size_with_continue_b | Computes BIFF record total size including CONTINUE record overhead. Same as compute_total_size_with_continue. |
| 0x00C97C50 | 16 | BIFFRecord__compute_size_simple_b | Computes simple BIFF record total size (data + 4 byte header, no CONTINUE). Same as compute_total_size_simple. |
| 0x00C97D00 | 33 | BIFFRecord__compute_size_with_continue_c | Computes BIFF record total size with CONTINUE overhead. Variant instance for specific record type. |
| 0x00C97D70 | 33 | BIFFRecord__compute_size_with_continue_d | Computes BIFF record total size with CONTINUE overhead. Variant instance for specific record type. |
| 0x00C97DA0 | 33 | BIFFRecord__compute_size_with_continue_e | Computes BIFF record total size with CONTINUE overhead. Variant instance for specific record type. |
| 0x00C97E70 | 33 | BIFFRecord__compute_size_with_continue_f | Computes BIFF record total size with CONTINUE overhead. Variant instance for specific record type. |
| 0x00C97EA0 | 33 | BIFFRecord__compute_size_with_continue_g | Computes BIFF record total size with CONTINUE overhead. Variant instance for specific record type. |
| 0x00C97ED0 | 33 | BIFFRecord__compute_size_with_continue_h | Computes BIFF record total size with CONTINUE overhead. Variant instance for specific record type. |
| 0x00C97F60 | 33 | BIFFRecord__compute_size_with_continue_i | Computes BIFF record total size with CONTINUE overhead. Variant instance for specific record type. |
| 0x00C97F90 | 16 | BIFFRecord__compute_size_simple_c | Computes simple BIFF record total size (data + 4 byte header, no CONTINUE). Variant instance. |
| 0x00C97FB0 | 75 | ExcelWorkbook__compute_total_data_size | Computes total workbook data size by summing sizes of all major sections: global records, SST, sheet data (via compute_all_sheets_size), and other sections. Calls vtable+0x10 on each section object. |
| 0x00C98000 | 102 | OLEStorage__delete_stream_by_path_ansi | ANSI string wrapper for OLEStorage__delete_stream_by_path. Converts narrow char* path to wchar_t* via mbstowcs, then calls the Unicode version to delete the stream. |
| 0x00C98070 | 104 | OLEStorage__delete_stream_by_path | Deletes a stream from the OLE storage by its Unicode path. Navigates to the directory entry, verifies it has no children (returns -3 if it does), removes the entry, rebuilds sector allocation, updates directory, and rewrites FAT sectors. |
| 0x00C980E0 | 102 | OLEStorage__delete_and_truncate_stream_ansi | ANSI string wrapper for OLEStorage__delete_and_truncate_stream. Converts narrow char* path to wchar_t* via mbstowcs, then calls the Unicode version. |
| 0x00C98150 | 214 | OLEStorage__delete_and_truncate_stream | Deletes an OLE stream by Unicode path, first truncating its data. If stream is >= 0x1000 bytes, reassigns sector chain via write_SST_strings. Then zeros the stream size, rebuilds allocation, removes directory entry, and rewrites FAT/directory sectors. |
| 0x00C98940 | 917 | ExcelWorkbook__write_to_ole_stream | Writes the entire Excel workbook to an OLE compound file stream. Computes total sizes for all sections and sheets, calculates stream offsets, writes BIFF record data, XF records, and each workbook section. Creates a "Workbook" stream entry in the OLE storage. |
| 0x00C98CE0 | 407 | ExcelWorkbook__save_to_file | Saves the Excel workbook to a file. Takes an ANSI filename, opens/initializes OLE storage, creates a "Workbook" directory entry, inserts it into the OLE directory tree, rebuilds sector allocation, then calls write_to_ole_stream to write all data. |
| 0x00C98E80 | 324 | OLEStorage__write_FAT_sectors | Writes all FAT sectors to the OLE storage file. Serializes FAT entries (sector allocation table), DIFAT entries (double-indirect FAT), and mini-FAT entries into 512-byte sector buffers and writes each via update_directory_entry. |
| 0x00C98FD0 | 30 | OLEStorage__rebuild_and_update_root | Rebuilds sector allocation and updates the root directory entry. Wrapper that calls rebuild_sector_allocation then update_directory_entry(0, buffer). |
| 0x00C98FF0 | 161 | OLEStorage__write_directory_entries | Serializes all OLE directory entries into a buffer (0x80 bytes per entry) and writes the buffer to the storage via write_SST_strings. Allocates buffer sized to sector boundaries, zeroes it, then fills with entry data via write_all_directory_entries. |
| 0x00C99700 | 221 | OLEStorage__tokenize_path | Splits a Unicode path at the last backslash. Outputs directory portion to param_2 and filename portion to param_3. If no backslash found, directory is empty and filename is the full path (skipping leading backslash if present). |
| 0x00C99840 | 172 | OLEStorage__swap_sectors | Swaps the contents of two sectors in the OLE storage. Reads both sectors via seek_and_read_sector, then writes each to the other's position via update_directory_entry. Requires write access (flag 0x02). Returns 1 on success, 0 on failure. |
| 0x00C99900 | 1929 | ExcelWorkbook__load_cell_data | Loads cell data from BIFF sheet records into CExcelVariant grid. Iterates over all sheets and cell records (0x2F8 stride). Dispatches by record type: MulRk (0xBD) decodes RK values, LabelSST (0xFD) reads SST strings (ANSI or Unicode), Number (0x203) stores doubles, BoolErr (0x205) stores booleans, RK (0x27E) decodes RK values. Populates variant grid at row/column positions. |
| 0x00C9A2E0 | 5482 | ExcelWorkbook__write_biff_record_data | Writes BIFF record data to Excel workbook stream. 5.4K bytes. Called by BIFFRecord__write_record_to_stream. Handles cell expansion, stream nodes, resource entries, string maps, and vector allocations for XLS file format output. |
| 0x00C9B860 | 529 | OLEStorage__build_row_table | Builds a row table for the OLE storage. Clears existing rows, reserves space, then iterates through storage entries (stride 0x124) building row descriptors. Each row descriptor is 0x1c bytes, pushed to a vector via emplace. Calls OLEStorage__save_to_file for each entry to populate data. |
| 0x00C9BA80 | 293 | OLEStorage__write_row_to_stream | Writes a row of data to the output stream. Seeks to the correct position via virtual call, writes multiple fields in little-endian (uint16 pairs at offsets 0x28/0x2a/0x2e, uint8 pair at 0x2c/0x2d, uint32 at 0x30, then a variable-length byte array from 0x34-0x38 range). Finishes with write_BIFF_record_with_continuations. |
| 0x00C9BBB0 | 297 | OLEStorage__write_row_fields | Writes row fields to the buffer. Serializes 4 uint16 fields (offsets 0x28, 0x2a, 0x2c, 0x2e) and 2 uint32 fields (offsets 0x30, 0x34) in little-endian byte order. Finishes with write_BIFF_record_with_continuations. |
| 0x00C9BCE0 | 339 | ExcelWorkbook__serialize_sheet_data | Serializes all data for a sheet. Iterates through sheet entries (stride 0x124), calling virtual serializers for header, sub-records, cell data, and footer sections. Accumulates total byte offset as return value. |
| 0x00C9BE40 | 223 | ExcelWorkbook__serialize_3_uint16_record | Serializes a BIFF record with 3 uint16 fields (at member offsets 0x28, 0x2a, 0x2c) to the output buffer. Seeks/resizes buffer via virtual call, writes fields in little-endian, then calls write_BIFF_record_with_continuations. |
| 0x00C9BF20 | 212 | OLEStorage__update_directory_entry | Updates an OLE directory entry on disk. Seeks to position (sector_size * index), writes the entry data, updates entry count and total size if index is at or beyond current count. Flushes and reopens the file stream. |
| 0x00C9C000 | 241 | ExcelWorkbook__serialize_3_uint16_plus_extra_record | Serializes a BIFF record with 3 uint16 fields (offsets 0x28, 0x2a, 0x2c) plus 2 extra bytes (offset 0x2e, 0x2f). Seeks/resizes buffer, writes in little-endian, then calls write_BIFF_record_with_continuations. |
| 0x00C9C100 | 163 | ExcelWorkbook__serialize_uint32_and_string_record | Serializes a BIFF record with 1 uint32 field (offset 0x28) + 2 single-byte fields + a string field via serialize_string_field. Then calls write_BIFF_record_with_continuations. |
| 0x00C9C1B0 | 152 | ExcelWorkbook__dispatch_record_serializer_by_type | Dispatches record serialization by BIFF record type code. Switch on type: 6=Formula, 0xbd=MulRk, 0xbe=MulBlank, 0xfd=LabelSST, 0x201=Blank, 0x203=Number, 0x205=BoolErr, 0x27e=RK. Each type accesses a different sub-object at varying offsets within the record structure. |
| 0x00C9C400 | 238 | ExcelWorkbook__serialize_uint32_and_uint16_array_record | Serializes a BIFF record with 1 uint32 field followed by a variable-length array of uint16 values from a vector. Writes count based on vector size, then each uint16 in little-endian. Calls write_BIFF_record_with_continuations. |
| 0x00C9C4F0 | 267 | ExcelWorkbook__serialize_2_uint32_3_uint16_record | Serializes a BIFF record with 2 uint32 fields + 3 uint16 fields to the output buffer in little-endian. Calls write_BIFF_record_with_continuations at end. |
| 0x00C9C600 | 326 | ExcelWorkbook__serialize_tuple_array_record | Serializes a BIFF record containing an array of (uint32, uint16, uint16) tuples from member vectors. Writes record type uint16, then iterates through entries writing each 8-byte tuple. Calls write_BIFF_record_with_continuations. |
| 0x00C9C750 | 354 | ExcelWorkbook__serialize_multi_field_with_string_record | Serializes a BIFF record with 5 uint16 fields + 4 single-byte fields + a string field via serialize_string_field. Calls write_BIFF_record_with_continuations at end. |
| 0x00C9C8C0 | 565 | ExcelWorkbook__serialize_complex_typed_record | Serializes a complex BIFF record: 3 uint16 fields, 8 raw bytes, 1 uint16, then a variable-length byte array from member vector. After writing data, dispatches to a type-specific sub-serializer based on a type code (0x36, 0xbc, 0x221, 0x4bc). Optionally writes an additional sub-record. Calls virtual finalize at end. |
| 0x00C9CB00 | 633 | OLEStorage__serialize_directory_entry_to_buffer | Serializes an OLE directory entry structure to a raw byte buffer in little-endian format. Copies 0x200+ bytes of fields including name (0x40 wchars), name length, type, color, SIDs (left/right/child), CLSID, state bits, timestamps, start sector, and size. |
| 0x00C9CD80 | 254 | ExcelWorkbook__serialize_4_uint32_and_array_record | Serializes a BIFF record with 4 uint32 fields followed by a variable-length array of uint32 values from a member vector. Writes fields in little-endian. Calls write_BIFF_record_with_continuations at end. |
| 0x00C9CE80 | 244 | ExcelWorkbook__serialize_3_uint16_1_uint32_record | Serializes a BIFF record header: 3 uint16 fields + 1 uint32 field to the output buffer in little-endian. Calls write_BIFF_record_with_continuations. |
| 0x00C9CF80 | 237 | ExcelWorkbook__serialize_string_data_field | Flushes a sector buffer to the output. Two modes based on flag bit 0: (0) writes narrow data - length uint16 + type byte + raw bytes; (1) writes wide data - length uint16 + type byte + wchar array via ole_write_wchar_array_to_buffer. Returns total bytes written (3 + data). |
| 0x00C9D070 | 350 | ExcelWorkbook__serialize_header_and_uint16_array_record | Serializes a BIFF record with 2 uint16 fields at beginning, 1 uint16 at variable offset (based on member field 5), then a variable-length array of uint16 values from a member vector. Calls write_BIFF_record_with_continuations. |
| 0x00C9D1D0 | 357 | ExcelWorkbook__serialize_header_and_tuple_array_record | Serializes a DIFAT-like table: 2 uint16 fields, 1 uint16 at variable offset, then an array of (uint16 + uint32) pairs from a member vector (stride 8). Calls write_BIFF_record_with_continuations. |
| 0x00C9D340 | 263 | ExcelWorkbook__serialize_3_uint16_1_uint64_record | Serializes a mini-FAT-like record: 3 uint16 fields + 1 uint64 field (written as 8 bytes from two uint32 members). Calls write_BIFF_record_with_continuations. |
| 0x00C9D450 | 473 | OLEStorage__serialize_single_directory_entry | Serializes a single OLE compound file directory entry (0x80 bytes) to a byte buffer. Writes: 32 wchar name chars, name size (uint16), type, color, left/right/child SIDs (uint32 each), CLSID, state bits, creation/modification timestamps, start sector, stream size. |
| 0x00C9D630 | 244 | ExcelWorkbook__serialize_3_uint16_1_uint32_record_v2 | Serializes a BIFF record with 3 uint16 fields + 1 uint32 field to the output buffer. Same pattern as write_header_to_buffer. Calls write_BIFF_record_with_continuations. |
| 0x00C9D730 | 624 | ExcelWorkbook__write_BIFF_record_with_continuations | Writes a BIFF record with CONTINUE records (type 0x3c) for data exceeding the max record size (0x2020 = 8224 bytes). Splits data at CONTINUE record boundaries, writing record type, size prefix, then data chunks. Handles both pre-split (via offset array) and raw data modes. |
| 0x00C9D9A0 | 371 | ExcelWorkbook__serialize_6_uint16_1_uint32_record | Serializes a BIFF record with 6 uint16 fields + 1 uint32 field to the output buffer. Calls write_BIFF_record_with_continuations at end. |
| 0x00C9DB20 | 292 | OLEStorage__serialize_storage_children | Serializes all child streams of an OLE storage entry. Iterates through two vectors: first (stride 0x38) for simple sub-records, second (stride 0x2f8) for complex typed records with type dispatch (same as dispatch_record_serializer_by_type). Ends with a final sub-record serialization. Returns total serialized bytes. |
| 0x00C9DD50 | 288 | ExcelWorkbook__write_global_records | Serializes workbook global records. Writes 2 uint32 fields, then iterates through sheet entries calling flush_sector_buffer for each, with optional vector byte inserts at specific offsets. Calls write_BIFF_record_with_continuations at end. |
| 0x00C9DE70 | 276 | ExcelWorkbook__write_sheet_records | Serializes sheet records. Writes 2 uint16 fields + 2 single-byte fields + 1 uint16 + 1 uint32, then copies a variable-length byte array from member vector. Calls write_BIFF_record_with_continuations. |
| 0x00C9DF90 | 276 | ExcelWorkbook__write_all_sheet_records | Serializes all sheet records (same structure as write_sheet_records). Writes 2 uint16 + 2 bytes + 1 uint16 + variable-length byte array. Calls write_BIFF_record_with_continuations. |
| 0x00C9E0B0 | 171 | ExcelWorkbook__serialize_string_field | Serializes a string field to a byte buffer. Writes length byte + type byte, then the string data. Supports both wide (wchar_t, type != 0) and narrow (char, type == 0) strings. Returns total bytes written (2 + string data length). |
| 0x00C9E160 | 201 | ExcelWorkbook__write_uint16_array_field | Writes an array of uint16 values from a vector to the output buffer. Iterates through the vector writing each uint16 in little-endian, then calls the BIFF record continuation handler. |
| 0x00C9E230 | 202 | ExcelWorkbook__write_cell_record | Serializes a BIFF cell record. Writes record type uint16, then conditionally: if type is negative, writes 2 raw bytes; otherwise calls flush_sector_buffer for the cell data. Calls write_BIFF_record_with_continuations at end. |
| 0x00C9E300 | 399 | ExcelWorkbook__write_row_record | Serializes a BIFF row record. Writes 8 uint16 fields (at offsets 0x28 through 0x36) to the output buffer in little-endian. Calls write_BIFF_record_with_continuations. |
| 0x00C9E490 | 459 | ExcelWorkbook__write_dimension_record | Serializes a BIFF dimension record. Writes 9 uint16 fields (at offsets 0x28 through 0x38) in little-endian to the output buffer. Calls write_BIFF_record_with_continuations. |
| 0x00C9E660 | 404 | ExcelWorkbook__write_format_record | Serializes a BIFF format record. Writes 7 uint16 fields + 1 uint32 field (18 bytes total) in little-endian to the output buffer. Calls write_BIFF_record_with_continuations. |
| 0x00C9E800 | 373 | ExcelWorkbook__serialize_workbook_globals | Serializes workbook global records. Calls virtual serializers for: header record, font records, multiple arrays of XF/format/style/palette records (strides 0x44, 0x40, 0x4c, 0x3c), SST record, and a final record. Returns total serialized bytes. |
| 0x00C9E980 | 205 | ExcelWorkbook__serialize_sheet_records | Serializes a sheet's records. Calls virtual serializers for header, cell index, row data, then iterates through cell records (stride 0x50), followed by footer and trailing records. Returns total serialized bytes. |
| 0x00C9EA50 | 333 | ExcelWorkbook__write_style_record | Serializes a BIFF style/XF record. Writes 3 uint16 fields + 4 raw bytes + 2 uint32 fields + 1 uint16 field (20 bytes total) in little-endian. Calls write_BIFF_record_with_continuations. |
| 0x00C9EBA0 | 75 | ExcelWorkbook__write_SST_header | Writes an SST header: 1 uint16 + 1 uint32 (6 bytes total) to the output buffer in little-endian. Contains the string count and unique string count for the Shared String Table. |
| 0x00C9EBF0 | 1964 | OLEStorage__write_stream_data_to_sectors | Writes stream data to OLE compound file sectors. Manages sector chain allocation: allocates new sectors if data grows, frees sectors if data shrinks, copies data to sectors in chunk size blocks. Handles both regular sectors (param_5 char==0, sector size from 0xbd) and mini-stream sectors (param_5 char!=0, sector size from 0xbc). |
| 0x00C9F3A0 | 110 | OLEStorage__add_stream_by_ansi_name | Adds a stream to the OLE storage by ANSI name. Converts the char* name to wchar_t via mbstowcs, then calls OLEStorage__write_stream_contents. The second param is dereferenced to get the stream data pointer. Frees the wide string after use. |
| 0x00C9F410 | 108 | OLEStorage__add_stream_by_ansi_name_direct | Adds a stream to the OLE storage by ANSI name (direct params). Converts char* name to wchar_t via mbstowcs, then calls OLEStorage__write_stream_contents with the data pointer directly. Frees the wide string after use. |
| 0x00C9F480 | 23 | OLEStorage__add_stream_by_wchar_name | Thin wrapper: adds a stream by wchar_t name. Dereferences param_2 to get stream data, then calls OLEStorage__write_stream_contents. |
| 0x00C9F4A0 | 183 | OLEStorage__write_stream_contents | Writes stream contents to the OLE compound file. Navigates to the target directory entry by path, determines if data should be in regular sectors (>=0x1000 bytes) or mini-stream (<0x1000 bytes), transitions between modes if needed, writes data via OLEStorage__write_stream_data_to_sectors, then rebuilds FAT, updates directory entry, and writes FAT sectors and directory entries to disk. |
| 0x00D588E0 | 142 | CResourceCache__handle_multipart_data | Handles multi-part resource data. Part 0: initializes with offset/size, stores cursor. Part 1: appends data bytes to buffer via range insert. Part 2: compresses accumulated data and saves to file, then notifies UI window. |
| 0x00E64260 | 207 | zlib_compress | zlib compress() - compresses source data into dest buffer using default compression level (-1). Initializes deflate stream, loops calling deflate until done. |
| 0x00E64330 | 208 | zlib_compress2 | zlib compress2() - compresses source data into dest buffer with specified compression level parameter. |
| 0x00E64400 | 30 | zlib_compressBound | zlib compressBound() - returns upper bound on compressed size for given source length. Formula: sourceLen + (sourceLen >> 12) + (sourceLen >> 14) + (sourceLen >> 25) + 13. |
| 0x00E64420 | 284 | zlib_uncompress | zlib uncompress() - decompresses source data into dest buffer. Initializes inflate stream, calls inflate in a loop. Returns 0 on success, error codes on failure. |
| 0x00E64540 | 288 | zlib_uncompress2 | zlib uncompress2() - decompresses with tracking of consumed source bytes via param_4. |
| 0x00E64660 | 1029 | zlib_deflate_stored | zlib deflate_stored() - handles stored (uncompressed) block output in deflate. Copies data directly when no compression needed, manages window sliding and lookahead buffer. |
| 0x00E64A70 | 1047 | zlib_deflate_fast | Zlib deflate fast, small utility function |
| 0x00E64E90 | 1381 | zlib_deflate_slow | Zlib deflate slow, small utility function |
| 0x00E65400 | 2563 | zlib_deflate | zlib deflate() main entry point. Manages deflate state machine (header writing, compression, trailer). Handles zlib/gzip/raw deflate formats. Dispatches to deflate_stored/fast/slow based on compression level. |
| 0x00E65E10 | 355 | zlib_deflateBound | zlib deflateBound() - returns upper bound on compressed size for given uncompressed size, accounting for stream format overhead. |
| 0x00E65F80 | 466 | zlib_deflateCopy | zlib deflateCopy() - copies a deflate stream state from source to dest. Allocates new internal buffers, copies hash tables and window data. |
| 0x00E66160 | 232 | zlib_deflateEnd | zlib deflateEnd() - frees all dynamically allocated data structures for the stream. Returns Z_DATA_ERROR if state was busy. |
| 0x00E66250 | 144 | zlib_deflateGetDictionary | zlib deflateGetDictionary() - copies the current sliding window dictionary to the caller's buffer and reports its length. |
| 0x00E662E0 | 568 | zlib_deflateInit2 | zlib deflateInit2_() - full initialization with all parameters: level, method, windowBits, memLevel, strategy. Allocates internal state and hash tables. |
| 0x00E66520 | 33 | zlib_deflateInit | zlib deflateInit_() - convenience wrapper calling deflateInit2 with default parameters (method=8, windowBits=15, memLevel=8, strategy=0). |
| 0x00E66550 | 406 | zlib_deflateParams | zlib deflateParams() - dynamically changes compression level and strategy. Flushes pending data if strategy or function pointer changes. |
| 0x00E666F0 | 121 | zlib_deflatePending | zlib deflatePending() - returns pending output bytes and bits count. |
| 0x00E66770 | 228 | zlib_deflatePrime | zlib deflatePrime() - inserts bits into the deflate output stream (up to 16 bits at a time). |
| 0x00E66860 | 398 | zlib_deflateReset | zlib deflateReset() - resets deflate state for reuse. Clears hash tables, resets lookahead and match state, reinitializes Huffman trees. |
| 0x00E669F0 | 229 | zlib_deflateResetKeep | zlib deflateResetKeep() - partial reset without clearing hash tables and configuration parameters. |
| 0x00E66AE0 | 490 | zlib_deflateSetDictionary | zlib deflateSetDictionary() - sets the deflate dictionary from caller-provided data, updating hash chains. |
| 0x00E66CD0 | 101 | zlib_deflateSetHeader | zlib deflateSetHeader() - sets the gzip header for deflate output (only valid for wrap mode 2). |
| 0x00E66D40 | 122 | zlib_deflateTune | zlib deflateTune() - overrides internal deflate parameters (good_length, max_lazy, nice_length, max_chain). |
| 0x00E66DC0 | 523 | zlib_deflate_huff | Zlib deflate huff, small utility function |
| 0x00E66FD0 | 883 | zlib_deflate_rle | Zlib deflate rle, small utility function |
| 0x00E67350 | 519 | zlib_fill_window | zlib fill_window() - reads input into the deflate sliding window. Handles window sliding when position is past midpoint, updates hash chain entries, fills lookahead from z_stream input. |
| 0x00E67560 | 78 | zlib_flush_pending | zlib flush_pending() - flushes pending output from the internal buffer to the z_stream output. Copies min(available, pending) bytes via memcpy. |
| 0x00E675B0 | 371 | zlib_longest_match | zlib longest_match() - finds the longest string match in the hash chain for LZ77. Compares bytes with optimizations (check last two bytes first, scan 8 bytes at a time). Returns match length. |
| 0x00E67730 | 44 | zlib_putShortMSB | zlib internal putShortMSB() - writes a 16-bit value in big-endian order to the deflate stream's pending output buffer. Increments pending count by 2. |
| 0x00E67760 | 123 | zlib_read_buf | zlib read_buf() - reads input from z_stream into a buffer, updating adler32/crc32 checksum based on wrap mode. |
| 0x00E677E0 | 98 | zlib_slide_hash | zlib slide_hash() - slides hash table entries back by one window length. Entries pointing before the new window are zeroed. Called when the window slides forward. |
| 0x00E67850 | 6048 | zlib_inflate | Core zlib inflate (decompression) function. 6K bytes. Called by zlib_uncompress, zlib_uncompress2, png_zlib_inflate. Processes compressed data using Huffman tables, sliding window, and fast inflate path. |
| 0x00E69080 | 66 | zlib_inflateGetDictionary_index | zlib inflateGetDictionary index helper - returns the window index for the inflate dictionary, or -1 on error. |
| 0x00E690D0 | 374 | zlib_inflateCopy | zlib inflateCopy() - copies an inflate stream from source to dest. Allocates new internal state and window buffer. |
| 0x00E69250 | 99 | zlib_inflateEnd | zlib inflateEnd() - frees all inflate stream resources (window buffer and internal state). |
| 0x00E692C0 | 128 | zlib_inflateGetDictionary | zlib inflateGetDictionary() - copies the inflate sliding window dictionary to caller buffer. Handles wraparound of the circular window buffer. |
| 0x00E69340 | 76 | zlib_inflateGetHeader | zlib inflateGetHeader() - registers a gz_header to receive gzip header info during inflate. |
| 0x00E69390 | 353 | zlib_inflateInit2 | zlib inflateInit2_() - initializes inflate state with windowBits parameter. Allocates internal state struct (0x1BD0 bytes). |
| 0x00E69500 | 24 | zlib_inflateInit | zlib inflateInit_() - convenience wrapper calling inflateInit2 with default windowBits=15. |
| 0x00E69520 | 123 | zlib_inflateMark | zlib inflateMark() - returns current decompression position as a combined value of back distance and bytes consumed. |
| 0x00E695A0 | 127 | zlib_inflatePrime | zlib inflatePrime() - inserts bits into inflate input bit buffer. Accepts negative value to clear. |
| 0x00E69620 | 290 | zlib_inflateReset | zlib inflateReset() - resets inflate state for reuse. Clears counters, resets state machine to initial state, preserves window allocation. |
| 0x00E69750 | 179 | zlib_inflateReset2 | zlib inflateReset2() - resets inflate with new windowBits. Frees window if size changes. |
| 0x00E69810 | 213 | zlib_inflateResetKeep | zlib inflateResetKeep() - minimal reset preserving more state than inflateReset. |
| 0x00E698F0 | 194 | zlib_inflateSetDictionary | zlib inflateSetDictionary() - sets the preset dictionary for inflate. Verifies adler32 checksum if in DICT state. |
| 0x00E699C0 | 321 | zlib_inflateSync | zlib inflateSync() - searches for next valid deflate block in the input stream after a data error. Drains bit buffer, searches for sync point. |
| 0x00E69B10 | 79 | zlib_inflateSyncPoint | zlib inflateSyncPoint() - returns 1 if inflate is at a block boundary with no pending bits, 0 otherwise. |
| 0x00E69B60 | 70 | zlib_inflateUndermine | zlib inflateUndermine() - enables/disables strict checking. Sets subvert flag and returns Z_DATA_ERROR. |
| 0x00E69BB0 | 84 | zlib_inflateValidate | zlib inflateValidate() - enables or disables checksum validation by setting/clearing bit 2 of the wrap field. |
| 0x00E69C10 | 99 | zlib_syncsearch | zlib syncsearch() - searches for a sync point (00 00 FF FF) marker in inflate input. Used by inflateSync. |
| 0x00E69C80 | 237 | zlib_updatewindow | zlib updatewindow() - copies output data to the inflate sliding window for dictionary/back-reference use. |
| 0x00E69E50 | 1062 | zlib_tr_flush_block | zlib _tr_flush_block() - flushes a Huffman or stored block to the output. Builds literal/distance trees, decides between static/dynamic/stored encoding. |
| 0x00E6A2E0 | 257 | zlib_tr_stored_block | zlib _tr_stored_block() - outputs a raw stored (uncompressed) block to the deflate bit stream. |
| 0x00E6A3F0 | 175 | zlib_tr_tally | zlib _tr_tally() - stores a literal byte or distance/length pair to the pending buffer. Updates frequency counts for literal and distance Huffman trees. Returns true when the buffer is full and a block should be flushed. Previously misnamed as build_bl_tree. |
| 0x00E6A580 | 671 | zlib_build_tree | zlib build_tree() - constructs an optimal Huffman tree for a given frequency table. Computes code lengths and generates canonical Huffman codes. |
| 0x00E6A820 | 1052 | zlib_compress_block | zlib compress_block() - outputs a compressed block using the given literal and distance Huffman trees. Encodes each literal/length/distance triple. |
| 0x00E6AC40 | 505 | zlib_gen_bitlen | Zlib gen_bitlen: computes optimal bit lengths for a Huffman tree to minimize total encoding size. |
| 0x00E6AE40 | 133 | zlib_init_block | zlib init_block() - initializes/resets all three Huffman frequency tables (literal 0x11E entries, distance 0x1E entries, bit-length 0x13 entries) and related counters to zero. Sets literal END marker frequency to 1. Previously misnamed as gen_codes. |
| 0x00E6AFC0 | 242 | zlib_scan_tree | Zlib scan_tree: scans a Huffman tree to determine the frequencies of bit length codes for compact encoding. |
| 0x00E6B0C0 | 619 | zlib_send_all_trees | Zlib send_all_trees: emits the Huffman tree descriptions (literal, distance, bit length) into the compressed output stream. |
| 0x00E6B330 | 1292 | zlib_send_tree | zlib send_tree() - encodes and sends a Huffman tree to the output bitstream using bit-length codes with run-length encoding. Handles repeat codes (16, 17, 18) for zero runs and repeated lengths. Previously misnamed as tr_init. |
| 0x00E6B840 | 9 | thunk_to_zlib_adler32_z_impl_00e6b840 | Thunk that calls FUN_00e6b9c0 and returns |
| 0x00E6B850 | 25 | zlib_adler32_combine | Zlib adler32_combine: combines two Adler-32 checksums computed over sequential data blocks. |
| 0x00E6B870 | 25 | zlib_adler32_combine64 | Zlib adler32_combine64: 64-bit length version of adler32_combine for combining sequential Adler-32 checksums. |
| 0x00E6B890 | 291 | zlib_adler32_combine_internal | zlib adler32 combine internal function. Combines two Adler-32 checksums from separate data blocks into a single checksum, using modular arithmetic with the Adler-32 prime (65521). Previously misnamed as adler32_z. |
| 0x00E6B9C0 | 625 | zlib_adler32_z_impl | zlib adler32_z() - computes Adler-32 checksum. Maintains two running sums (s1, s2) modulo 65521 (0xFFF1). Processes data in 16-byte unrolled chunks (NMAX=5552 bytes between modulo ops). Returns (s2 << 16) \| s1. Previously misnamed as crc32_z. |
| 0x00E6BC40 | 9 | thunk_to_zlib_crc32_generic_00e6bc40 | Thunk that calls FUN_00e6bd10 and returns |
| 0x00E6BC50 | 36 | zlib_crc32_combine | Zlib crc32_combine: combines two CRC-32 checksums computed over sequential data blocks. |
| 0x00E6BC80 | 36 | zlib_crc32_combine64 | Zlib crc32_combine64: 64-bit length version of crc32_combine for combining sequential CRC-32 checksums. |
| 0x00E6BCB0 | 21 | zlib_crc32_combine_gen | Zlib crc32_combine_gen: generates a CRC-32 combine operator matrix for a given length. |
| 0x00E6BCD0 | 21 | zlib_crc32_combine_gen64 | Zlib crc32_combine_gen64: 64-bit length version of crc32_combine_gen. |
| 0x00E6BCF0 | 22 | zlib_crc32_combine_op | Zlib crc32_combine_op: combines a CRC-32 checksum using a precomputed operator matrix. |
| 0x00E6BD10 | 1028 | zlib_crc32_generic | Zlib crc32_generic: computes CRC-32 checksum over a byte buffer using table-based polynomial division. |
| 0x00E6C130 | 62 | zlib_gf2_matrix_times | Zlib gf2_matrix_times: multiplies a GF(2) matrix by a vector, used in CRC-32 combine operations. |
| 0x00E6C170 | 137 | zlib_gf2_matrix_square | Zlib gf2_matrix_square: squares a GF(2) matrix in-place, used for CRC-32 combine operator generation. |
| 0x00E6C200 | 20 | png__get_data_table_ptr | PNG data table accessor. Returns pointer from PTR_DAT_011bade8 indexed by negative offset of param_1. NOT zlib zcalloc. |
| 0x00E6C220 | 22 | zlib_zcalloc_impl | Zlib zcalloc: allocates memory for zlib internal structures (items * size bytes via calloc). |
| 0x00E6C240 | 17 | zlib_zcfree | Zlib zcfree: frees memory previously allocated by zcalloc. |
| 0x00E6C280 | 1304 | zlib_inflate_table | Zlib inflate_table: builds Huffman decoding tables from a set of code lengths for inflate decompression. |
| 0x00E6C7A0 | 1057 | zlib_inflate_fast | Zlib inflate_fast: optimized inner loop for inflate decompression, decodes literal/length and distance codes directly. |
| 0x00E6CD80 | 45 | png__icc_profile_check_length | PNG ICC profile length validator. Returns 0 (via png__icc_profile_error with "too short") if param_4 < 0x84 (132 bytes minimum ICC header). Returns 1 if length is valid. |
| 0x00E6CDB0 | 93 | png__validate_keyword_chars | PNG keyword string validator. Checks that all 4 bytes extracted from input are valid keyword characters (alphanumeric or space). Returns 1 if all valid, 0 if any invalid. |
| 0x00E6CE10 | 52 | png__is_keyword_char | PNG keyword character validator. Returns 1 if the character is a space (0x20), digit (0-9), uppercase letter (A-Z), or lowercase letter (a-z). Returns 0 otherwise. |
| 0x00E6CE50 | 763 | png__check_cHRM_fixed | PNG cHRM chunk validator + xy-to-XYZ conversion. Validates chromaticity endpoints (range 0-100000), computes colorspace matrix using png__muldiv and png__reciprocal. Returns 0 on success, 1 on invalid values, 2 on math error. |
| 0x00E6D150 | 439 | png__colorspace_endpoints_normalize | PNG colorspace endpoint normalizer. Takes 9 fixed-point color values (RGB x3 channels) and normalizes them so each row sums to 100000 using png__muldiv. Returns 0 on success, 1 on failure. |
| 0x00E6D320 | 275 | png__ascii_from_fixed | PNG fixed-point to ASCII converter. Converts a fixed-point integer (scale factor 100000) to a decimal string. Handles negative values, writes digits with decimal point at position 5. Calls png__error if buffer too small (min 13 bytes). |
| 0x00E6D440 | 1141 | png__ascii_from_fp_double | libpng: Converts a floating-point double value to an ASCII decimal string. Handles negative values, scientific notation (E+/E-), and precision control. Calls png__error if buffer is too small. This is the floating-point version; png__ascii_from_fixed handles fixed-point integers. |
| 0x00E6D8C0 | 400 | png__build_gamma_table | PNG gamma table builder. Allocates and populates gamma correction lookup tables. Uses png_calloc for table array, png_malloc for 256-entry sub-tables. Applies gamma-significant check to decide between linear scaling and power-curve calculation. |
| 0x00E6DA50 | 292 | png__build_16bit_gamma_table | libpng: Builds a 16-bit gamma lookup table. Allocates a 2D table (shift-based subdivision) and fills entries using gamma correction values. Each table entry maps 16-bit color values through the gamma curve. |
| 0x00E6DB80 | 95 | png__build_8bit_gamma_table | libpng: Builds an 8-bit (256-entry) gamma lookup table. If a gamma transform is active, maps each byte through the gamma function; otherwise fills with identity mapping (0-255). |
| 0x00E6DBE0 | 511 | png__build_gamma_tables | libpng: Master gamma table builder. Handles both 8-bit and 16-bit cases depending on bit depth. Builds encoding/decoding tables and optional alpha channel tables. Logs "gamma table being rebuilt" warning and frees old tables before rebuilding. |
| 0x00E6DDE0 | 29 | png__build_default_palette | libpng: Builds a default color palette based on bit depth (1, 2, 4, 8-bit). Creates RGB triplets with evenly-spaced values for the given color depth. Switch cases handle different depths with appropriate step sizes. |
| 0x00E6DE70 | 109 | png__update_adler32 | libpng: Updates Adler-32 checksum (CRC) over a data buffer. Feeds data through the CRC calculation function in chunks, updating the running CRC stored at offset 0x13c in the PNG struct. |
| 0x00E6DEE0 | 509 | png__validate_IHDR | libpng: Validates all IHDR (Image Header) parameters. Checks width/height (zero, negative, user limit), bit depth (1/2/4/8/16), color type (0/2/3/4/6), interlace method, compression method, and filter method. Reports errors via png_error for invalid combinations. |
| 0x00E6E0E0 | 244 | png__parse_number_state_machine | libpng: State machine to parse a number from a character buffer. Handles digits (0-9), sign (+/-), decimal point (.), and exponent (E/e). Returns 1 if a valid number was found, updates state and position through output pointers. |
| 0x00E6E270 | 77 | png__check_number_string | libpng: Checks if a string represents a valid number. Wrapper around png__parse_number_state_machine. Returns the parsed state if the entire string was consumed, 0 otherwise. |
| 0x00E6E2C0 | 80 | png__save_uint_32_to_string | libpng: Converts a 32-bit unsigned integer to a big-endian byte string with null terminator. Stores the 4 bytes in MSB-first order for PNG chunk data formatting. |
| 0x00E6E310 | 80 | png__check_chromaticity_endpoints | libpng: Checks chromaticity endpoints (xy values). Calls png__colorspace_check_xy to validate, then copies the endpoint data to local buffer and calls png__colorspace_set_endpoints if invalid. |
| 0x00E6E360 | 134 | png__colorspace_check_gamma | libpng: Checks gamma value against the colorspace. If gamma flag bit is not set, returns true. Otherwise validates the gamma value matches libpng or sRGB expectations. Warns on mismatch with appropriate error level based on param_4. |
| 0x00E6E3F0 | 69 | png__colorspace_check_xy | libpng: Validates chromaticity xy endpoints. Converts to XYZ, checks if XYZ values match within tolerance of 5 units, and returns 0 if valid, nonzero on error. |
| 0x00E6E440 | 214 | png__colorspace_endpoints_match | libpng: Compares two sets of chromaticity/colorspace endpoints (8 int values each) within a given tolerance. Returns 1 if all 8 values match within the tolerance range, 0 otherwise. |
| 0x00E6E520 | 117 | png__icc_check_and_set_profile | libpng: Validates and sets an ICC color profile on the colorspace. Checks profile length, header, tag table, and attempts sRGB detection. Returns 1 on success, 0 if colorspace is already invalid. Previously misnamed as png__colorspace_set_chromaticities. |
| 0x00E6E5A0 | 110 | png__colorspace_set_chromaticities_from_xy | libpng: Sets colorspace chromaticities from xy values. Validates the xy data, then calls png__colorspace_set_chromaticities_internal. Errors "invalid chromaticities" on bad data or fatal "internal error" on unexpected return. |
| 0x00E6E610 | 136 | png__colorspace_set_endpoints | libpng: Sets colorspace endpoints from XYZ values. Copies 9 endpoint values to local storage, validates via png__check_chromaticity_endpoints, then stores into the colorspace. Errors "invalid end points" on bad data. |
| 0x00E6E6A0 | 124 | png__colorspace_set_gamma | libpng: Sets gamma value on a colorspace structure. Validates gamma range (>= 16, < 0x2540BE40), checks for duplicates, verifies against existing gamma if check_gamma flag set. Stores gamma value and marks colorspace as having gamma. |
| 0x00E6E720 | 345 | png__colorspace_compute_XYZ_coefficients | libpng: Computes XYZ color coefficients from cHRM chunk data. Normalizes RGB-to-XYZ values so they sum to 0x8000 (the PNG fixed-point representation of 1.0). Adjusts the largest component to fix rounding. Fatal error on invalid cHRM data. |
| 0x00E6E880 | 264 | png__colorspace_set_sRGB | libpng: Sets sRGB colorspace with rendering intent. Validates intent (0-3), checks for duplicates, verifies cHRM matches sRGB standard values. Sets sRGB gamma (0xB18F=45455), sRGB chromaticities, and sRGB ICC profile data. Returns 1 on success, 0 on error. |
| 0x00E6E990 | 218 | png__colorspace_set_chromaticities_internal | libpng: Internal implementation to set chromaticities on a colorspace. Checks for inconsistencies with existing chromaticities, copies xy and XYZ endpoint data, and checks if values match sRGB standard (within tolerance of 1000). Returns 2 on success, 0 on inconsistency. |
| 0x00E6EA70 | 93 | png__copy_colorspace_to_info | libpng: Copies colorspace data from png_struct (offsets 0x2C8-0x310) to png_info (offsets 0x28-0x70). Transfers chromaticity endpoints, XYZ coefficients, and gamma data. Calls png__update_info_colorspace_flags afterward. |
| 0x00E6EAD0 | 111 | png__update_info_colorspace_flags | libpng: Updates png_info valid flags based on colorspace status flags. Sets/clears sRGB (0x800), cHRM (0x4), and gAMA (0x1) valid bits in info_ptr->valid (offset 0x8) based on the colorspace status word at offset 0x72. |
| 0x00E6EB40 | 467 | png__icc_check_known_sRGB_profiles | libpng: Checks an ICC profile against known sRGB profiles. Compares profile header fields (MD5, size, date) against a table of 7 known sRGB profiles. Warns about out-of-date or incorrect profiles. Returns match index + 1, or 0 if no match. |
| 0x00E6ED20 | 60 | png__convert_time_to_string | libpng: Converts a png_time struct to a formatted string. Writes to buffer at png_struct+0x214. Warns "Ignoring invalid time value" on validation failure. |
| 0x00E6ED60 | 415 | png__format_time_string | libpng: Formats a png_time to a human-readable date string (e.g. "DD Mon YYYY HH:MM:SS +0000"). Validates year<10000, month 1-12, day 1-31, hour<24, minute<60, second<61. Returns 1 on success, 0 on invalid time. |
| 0x00E6EF00 | 54 | png__create_info_struct | libpng: Allocates and zero-initializes a png_info struct (0x118 bytes). Returns pointer to the new info struct, or NULL if png_ptr is NULL or allocation fails. |
| 0x00E6EF40 | 397 | png__create_read_struct | libpng: Creates a PNG read structure. Initializes a local png_struct with error handling (setjmp), user limits (1M width/height, 1000 chunks), and callbacks. Copies the struct to a heap-allocated buffer (0x314 bytes). Returns the read struct or NULL on failure. |
| 0x00E6F0D0 | 65 | png__data_freer | libpng: Sets or clears data ownership flags for png_info data. param_3=1 sets the flag bits (png frees), param_3=2 clears them (user frees). Fatal error on unknown freer parameter. Flags stored at info_ptr offset 0xF4. |
| 0x00E6F120 | 361 | png__free_gamma_tables | libpng: Frees all gamma lookup tables from the PNG struct. Releases the 8-bit table (offset 0x190), 16-bit table arrays (offsets 0x194, 0x1A0, 0x1A4) including their sub-tables, and the background gamma table (0x198, 0x19C). Nullifies all pointers after freeing. |
| 0x00E6F290 | 72 | png__destroy_info_struct | libpng: Destroys a png_info struct. Frees owned data via png__free_info_data, zeroes the 0x118 byte struct, then frees the struct itself. Sets the info pointer to NULL. |
| 0x00E6F2E0 | 96 | png__float_to_fixed_point | libpng: Converts a double-precision float to PNG fixed-point integer (multiplied by 100000). Floors the result with 0.5 rounding. Fatal error if result overflows int range. |
| 0x00E6F340 | 1228 | png__free_info_data | libpng: Frees data owned by a png_info struct based on ownership flags (offset 0xF4). Handles text chunks (0x4000), tRNS (0x2000), sCAL (0x100), iCCP (0x80), sPLT (0x20), unknown chunks (0x200), PLTE (0x1000), hIST (0x8), pCAL (0x10), rows (0x40), and eXIf (0x8000). Clears corresponding valid bits. |
| 0x00E6F810 | 106 | png__gamma_16bit_correct | libpng: Applies gamma correction to a 16-bit value. Converts to [0,1] range, raises to gamma power via pow(), and converts back to 16-bit. Returns input unchanged for 0 and 0xFFFF edge cases. |
| 0x00E6F880 | 111 | png__gamma_8bit_correct | libpng: Applies gamma correction to an 8-bit value. Converts to [0,1] range (divides by 255.0), raises to gamma power via pow(), and converts back to 8-bit. Returns input unchanged for 0 and 255. |
| 0x00E6F8F0 | 44 | png__gamma_correct | libpng: Applies gamma correction to a color value. Dispatches to 8-bit or 16-bit gamma correction based on bit depth (offset 0x154). Returns corrected value masked to appropriate bit width. |
| 0x00E6F920 | 24 | png__gamma_significant | libpng: Returns true if a gamma value is significantly different from 1.0. Tests if value is outside range 95000-105000 (i.e. not within 5% of unity/100000). |
| 0x00E6F950 | 6 | png__get_version_string_ptr | libpng: Returns pointer to the libpng version string at DAT_0111ade0. |
| 0x00E6F970 | 17 | png__get_io_ptr | libpng: Returns the I/O pointer (user data) stored at offset 0x60 in the png_struct. Returns 0 if png_ptr is NULL. |
| 0x00E6F990 | 9 | thunk_to_png__get_version_string_ptr | Thunk to png__get_version_string_ptr, returns pointer to the libpng version string. |
| 0x00E6F9A0 | 64 | png__get_chunk_filter_flag | libpng: Looks up a chunk name in the chunk filter list (stored at offsets 0x244/0x248). Searches backward through the list of 5-byte entries (4-byte chunk name + 1-byte flag). Returns the flag byte if found, 0 if not found or list is empty. |
| 0x00E6F9E0 | 779 | png__icc_check_header | libpng: Validates an ICC profile header. Checks: length match, alignment, tag count, rendering intent (0-3), signature ('acsp'), PCS illuminant (D50), color space (GRAY/RGB matching image type), profile class (mntr/scnr/prtr/spac allowed, abst/link/nmcl rejected), and PCS encoding (Lab/XYZ). Returns 1 if valid. |
| 0x00E6FCF0 | 83 | png__icc_check_length | libpng: Checks ICC profile length against application limits. First validates basic length, then checks if it exceeds the user-specified maximum profile length (offset 0x288). Returns 1 if valid, 0 if exceeds limit. |
| 0x00E6FD50 | 253 | png__icc_check_tag_table | libpng: Validates ICC profile tag table entries. Checks that each tag's offset+size fits within the profile, and that tag offsets are 4-byte aligned. Returns 1 if all tags are valid. |
| 0x00E6FE50 | 310 | png__icc_profile_error | libpng: Formats and reports an ICC profile error. Builds a message like "profile '<name>': <value>: <description>". Sets the colorspace invalid flag (0x8000) if a colorspace is provided. Reports as warning (level 1) or error (level 2) depending on whether colorspace was provided. |
| 0x00E6FF90 | 75 | png__icc_set_sRGB_if_known | libpng: Checks if the ICC profile matches a known sRGB profile and if so, sets sRGB colorspace with the rendering intent extracted from the profile header at offset 0x40. |
| 0x00E6FFE0 | 21 | png__sanitize_byte_to_printable | libpng: Sanitizes a byte to printable ASCII range. Returns the byte if in range [0x20, 0x7E], otherwise returns '?' (0x3F). |
| 0x00E70000 | 72 | png__format_chunk_tag | libpng: Formats a 4-byte chunk tag into a quoted printable string like "'IHDR'". Sanitizes each byte to printable ASCII, wrapping in single quotes. |
| 0x00E70050 | 41 | png__image_error | libpng: Sets an error message on a png_image struct. Copies the error string to the message buffer (offset 0x20, max 0x40), sets the error flag bit (0x2) in flags at offset 0x1C, then calls the cleanup handler. |
| 0x00E70080 | 47 | png__image_free | libpng: Frees a png_image's internal control structure. Checks that the image, control pointer, and reference count (at control+8) are valid. Calls the cleanup callback then NULLs the control pointer. |
| 0x00E700B0 | 157 | png__image_read_cleanup | libpng: Cleanup callback for png_image read operations. Closes the FILE handle if owned (flag bit 2), copies control data to stack, frees the control struct, then calls either png_read_end or png_destroy_read_struct depending on the high-bit flag. Returns 1 on success, 0 if no png_ptr. |
| 0x00E70150 | 74 | png__image_init_info | libpng: Initializes or reallocates a png_info struct for a png_image. If the existing struct is too small (< 0x118 bytes), frees it and allocates a new one. Zeroes the 0x118-byte struct. |
| 0x00E701A0 | 18 | png__set_io_ptr | libpng: Sets the I/O pointer (user data) at offset 0x60 in png_struct. This is typically a FILE* or custom I/O struct used by read/write callbacks. |
| 0x00E701C0 | 164 | png__muldiv | libpng: Computes (param_2 * param_3) / param_4 with overflow protection using double-precision float intermediary. Returns 1 on success (result stored in *param_1), 0 on division by zero or overflow. |
| 0x00E70270 | 58 | png__muldiv_warn | libpng: Wrapper around png__muldiv that warns on overflow. Returns the computed value, or 0 with a "fixed point overflow ignored" warning on failure. |
| 0x00E702B0 | 113 | png__pow2 | libpng: Computes 2^n using repeated squaring (exponentiation by squaring). Handles negative exponents by computing 1/(2^\|n\|). Returns 0 for very negative values (< -307). Used for floating-point gamma calculations. |
| 0x00E70330 | 110 | png__reciprocal2 | libpng: Computes the product of two values scaled by a constant (reciprocal of 100000). Used for combining two gamma values. Returns 0 on overflow. |
| 0x00E703A0 | 103 | png__reciprocal | libpng: Computes the reciprocal of a gamma value (constant / param_1). Used to invert gamma for encoding/decoding. Returns 0 on overflow. |
| 0x00E70410 | 126 | png__reciprocal_product | libpng: Computes constant / (param_1 * param_2) for gamma inverse product. Used when combining screen gamma and file gamma. Returns 0 on overflow or if either input is 0. |
| 0x00E70490 | 28 | png__reset_crc | libpng: Resets the CRC-32 value in png_struct (offset 0x13C) to initial state by calling crc32(0, NULL, 0). |
| 0x00E704B0 | 31 | png__reset_zstream | libpng: Resets the zlib decompression stream. Returns -2 (Z_STREAM_ERROR) if png_ptr is NULL, otherwise delegates to inflateReset. |
| 0x00E704D0 | 5 | png__save_uint_32 | libpng: png_save_uint_32, stores a 32-bit integer as 4 big-endian bytes to a buffer. Standard PNG byte-order serialization. |
| 0x00E704E0 | 85 | png__set_check_for_invalid_index | libpng: Sets the palette index checking mode. param_2 selects which 2-bit field in the mode word (offset 0x210) to modify. param_3 controls the new value (2 if 0, 3 if nonzero). Returns the previous value of that field. |
| 0x00E70540 | 44 | png__set_sig_bytes | libpng: Tells libpng how many PNG signature bytes have already been read. Stores count at offset 0x159. Fatal error if count exceeds 8 (the full PNG signature length). |
| 0x00E70570 | 223 | png__sig_cmp | libpng: Compares bytes against the PNG signature (89 50 4E 47 0D 0A 1A 0A). param_2 is the starting offset into the signature, param_3 is the number of bytes to check. Returns 0 if match, -1 or 1 on mismatch. |
| 0x00E70650 | 293 | png__check_version | libpng: Checks if the application was compiled with a compatible libpng version. Compares the compile-time version string against the runtime version up to the second dot. Warns "Application built with libpng X but running with Y" on mismatch. Returns 1 if compatible. |
| 0x00E70780 | 332 | png__xy_from_XYZ | libpng: Converts XYZ colorspace values to xy chromaticity coordinates. Computes x=X/(X+Y+Z) and y=Y/(X+Y+Z) for R, G, B primaries and white point using png__muldiv. Returns 0 on success, 1 on overflow. |
| 0x00E708D0 | 59 | png__zalloc | libpng: Allocator callback for zlib. Computes total size (items * size) with overflow check. Warns "Potential overflow in png_zalloc" if multiplication would overflow. Returns allocated memory or NULL. |
| 0x00E70910 | 5 | thunk_to_png_free_default | Thunk to png_free_default, calls the custom free callback at png_ptr+0x264 if set, otherwise falls through to png_free_default (C free). |
| 0x00E70920 | 157 | png__set_zlib_error_message | libpng: Maps zlib return codes to human-readable error strings. Handles Z_STREAM_END(1), Z_NEED_DICT(2), Z_ERRNO(-1), Z_STREAM_ERROR(-2), Z_DATA_ERROR(-3), Z_MEM_ERROR(-4), Z_BUF_ERROR(-5), Z_VERSION_ERROR(-6), and a special truncated code(-7). Stores message at offset 0x9C only if not already set. |
| 0x00E709F0 | 104 | png__image_sample_convert | libpng: Converts an 8-bit sample value to the target encoding (linear/sRGB/gamma). Mode 1: lookup table, mode 3: gamma correction via png__gamma_16bit_correct, mode 4: simple 8-to-16 bit expansion (multiply by 0x101), default: pass through. |
| 0x00E70A60 | 160 | png__image_create_colormap_alpha | libpng: Creates a colormap with alpha channel entries. Generates grayscale ramp entries (0x73 step/0xE7 divisor), a fully transparent white entry, then additional alpha-graduated entries in 0x33 steps. Each entry is added via png__image_add_colormap_entry. |
| 0x00E70B00 | 51 | png__image_create_colormap_gray | libpng: Creates a 256-entry grayscale colormap. Each entry maps index N to (R=N, G=N, B=N, A=0xFF) with encoding mode 1 (sRGB). |
| 0x00E70B40 | 51 | png__image_create_colormap_gray_linear | libpng: Creates a 256-entry linear grayscale colormap. Same as gray version but uses encoding mode 3 (linear/gamma-corrected) instead of mode 1 (sRGB). |
| 0x00E70B80 | 90 | png__image_create_colormap_rgb | libpng: Creates a 6x6x6 RGB color cube colormap (216 entries). Iterates R, G, B in steps of 0x33 (0, 51, 102, 153, 204, 255) producing 216 entries, all with alpha=0xFF and encoding mode 1 (sRGB). |
| 0x00E70BE0 | 131 | png__image_compose_sample | libpng: Composites a foreground sample over a background sample using alpha blending. Converts both samples via png__image_sample_convert, blends using alpha, then converts back to target encoding (sRGB lookup table or linear). |
| 0x00E70C70 | 1286 | png__image_add_colormap_entry | libpng: Adds a single RGBA entry to a colormap at the given index. Handles color type conversion (grayscale vs RGB), encoding conversion (sRGB/linear/gamma), alpha premultiplication for linear mode, and different output formats (8-bit/16-bit, with/without alpha, BGR/RGB order). Fatal error on index >= 256 or encoding mismatch. |
| 0x00E711A0 | 31 | png__create_read_struct_simple | libpng: Simplified wrapper for png__create_read_struct_2 that passes NULL for the custom memory allocator/deallocator. Creates a png_read_struct with just version, error_ptr, error_fn, and warning_fn. |
| 0x00E711C0 | 81 | png__create_read_struct_2 | libpng: Creates a PNG read struct with custom allocator. Calls png__create_read_struct, sets mode flags (0x300000), valid flag (0x8000), chunk limit (0x2000), and configures CRC handling via set_crc_action(0,0). |
| 0x00E71220 | 61 | png__destroy_read_struct | libpng: Destroys a PNG read struct and its associated info structs. Destroys both end_info and info structs, then calls png_read_destroy to clean up internal state, and finally frees the png_struct itself. |
| 0x00E71260 | 210 | png__do_read_transformations_rgb_delta | libpng: Applies RGB delta decoding to a row. For color types 2 (RGB) and 6 (RGBA), converts delta-encoded R,G,B channels by adding the G channel value to R and B. Handles both 8-bit and 16-bit (big-endian) samples. |
| 0x00E71340 | 57 | png__gamma_threshold_check | libpng: Checks if gamma correction is needed. Returns 1 if gamma >= 100000 (trivially above), 0 if gamma is 0, or delegates to png__gamma_significant to check if gamma differs meaningfully from 1.0. |
| 0x00E71380 | 171 | png__image_begin_read_from_file | libpng: Begins reading a PNG image from a file path. Validates state (version must be 1), opens the file with fopen, initializes read control, sets the FILE pointer as I/O ptr, marks the file as owned (flag 2), and starts header reading. Closes file on init failure. |
| 0x00E71430 | 139 | png__image_begin_read_from_memory | libpng: Begins reading a PNG image from a memory buffer. Validates state and params, sets up the memory buffer pointer and length in the control struct, installs a custom memory read callback, and starts header reading. |
| 0x00E714C0 | 106 | png__image_begin_read_from_stdio | libpng: Begins reading a PNG image from an open FILE* (stdio). Validates state and non-null FILE, sets FILE as the I/O pointer (without owning it), and starts header reading. |
| 0x00E71530 | 466 | png__image_finish_read | libpng: Completes reading a PNG image into user buffer. Validates parameters (buffer, stride, overflow), determines colormap vs direct mode, dispatches to appropriate colormap or direct read processor, then frees the image control. Returns 1 on success. |
| 0x00E71710 | 66 | png__image_get_format_flags | libpng: Gets the image format flags from the PNG struct. Bit 0: alpha channel present, bit 1: color (not grayscale), bit 2: 16-bit depth, bit 3: interlaced. Checks color type, tRNS presence, bit depth, and interlace flag. |
| 0x00E71760 | 97 | png__image_memory_read_callback | libpng: Custom read callback for memory-based PNG reading. Copies requested bytes from the memory buffer, advancing the pointer and decreasing remaining length. Fatal error "read beyond end of data" if buffer exhausted or "invalid memory read" if I/O pointer is NULL. |
| 0x00E717D0 | 474 | png__image_read_colormap_to_indexed | libpng: Reads PNG rows and converts to colormap-indexed output. Handles different colormap encoding types (gray+alpha, gray+transparent, RGB, RGBA) with interlace support. Processes each pixel through quantization to find nearest colormap index for output. |
| 0x00E71B70 | 1467 | png__image_read_direct_alpha_compose | libpng: Reads PNG rows with alpha compositing for direct (non-colormap) output. Handles 8-bit and 16-bit grayscale with alpha, compositing against background color using sRGB lookup tables. Supports both transparent background and user-specified background with interlace handling. |
| 0x00E72130 | 301 | png__image_read_colormap_setup | libpng: Sets up colormaps for simplified API image reading. Handles all PNG color types (gray, palette, gray+alpha, RGB, RGBA) with optional transparency, background composition, and gamma correction. Creates appropriate colormap entries and configures read transforms. Very complex function handling all colormap generation cases. |
| 0x00E72FF0 | 96 | png__image_read_colormap_process | libpng: Processes colormap-based PNG image reading. Validates the expected post-transform format, sets up row buffer, and either directly reads rows to output or dispatches to png__image_read_colormap_to_indexed for indexed conversion. Handles interlace passes and palette max calculation. |
| 0x00E731D0 | 642 | png__image_read_direct_alpha_blend_rows | libpng: Reads PNG rows with per-pixel alpha blending for direct output. Composites each pixel against background using sRGB linearization tables. Handles interlaced images, supports both gray+alpha and RGB+alpha color types. Used when alpha needs compositing but output is 8-bit sRGB. |
| 0x00E73460 | 1207 | png__image_read_direct | libpng: Main direct (non-colormap) image read function. Sets up all necessary transforms (color conversion, gamma, alpha handling, bit depth, interlace, swap), reads rows into user buffer. Dispatches to alpha blend/compose helpers when needed. Handles format flag mismatches with fatal errors. |
| 0x00E73920 | 166 | png__image_read_header | libpng: Reads and processes the PNG header for the simplified API. Calls png_read_info, extracts width/height/format flags, detects sRGB colorspace capability, and determines maximum colormap size based on color type and bit depth. Stores results in the image control struct. |
| 0x00E739D0 | 203 | png__image_read_init_control | libpng: Initializes the internal control structure for the simplified PNG image read API. Creates read struct, info struct, and a 0x18-byte control block. Sets error/warning callbacks and links everything together. Returns 1 on success, 0 with error message on failure. |
| 0x00E73AA0 | 39 | png__set_keep_unknown_chunks | libpng: Configures handling of unknown chunks. Sets default behavior to keep=1 (handle normally), then sets specific chunk types from a list of 6 chunks (at DAT_011bc338) to default handling (keep=0). |
| 0x00E73AD0 | 314 | png__read_destroy | libpng: Destroys internal state of a PNG read struct. Frees gamma tables, IDAT buffer, row buffer, previous row, chunk list, palette (if owned), tRNS data (if owned), zlib stream, old row buffer, and all other allocated memory. Nullifies all pointers. |
| 0x00E73C10 | 833 | png__read_end | libpng: Reads remaining chunks after image data (IEND). Finishes IDAT processing, checks palette index warnings, then loops reading chunk headers and dispatching to appropriate handlers (IHDR, IEND, PLTE, bKGD, cHRM, eXIf, gAMA, hIST, oFFs, pCAL, sCAL, pHYs, sBIT, sRGB, iCCP, sPLT, tEXt, tIME, tRNS, zTXt, iTXt) until IEND is found. |
| 0x00E73F60 | 170 | png__read_image | libpng: Reads the entire PNG image into an array of row pointers. Handles interlace by reading multiple passes. If interlace handling is not set up by the user, warns about it. Calls png_read_row for each row in each interlace pass. |
| 0x00E74010 | 810 | png__read_info | libpng: Reads PNG header and all chunks before image data. Reads signature, then loops reading chunk headers and dispatching to handlers until IDAT is found. Handles all standard chunk types (IHDR, PLTE, bKGD, cHRM, eXIf, gAMA, hIST, oFFs, pCAL, sCAL, pHYs, sBIT, sRGB, iCCP, sPLT, tEXt, tIME, tRNS, zTXt, iTXt). Returns with IDAT length stored for subsequent row reading. |
| 0x00E74340 | 456 | png__read_png | libpng: High-level function to read an entire PNG. Reads header info, applies requested transforms (strip 16-bit, strip alpha, packing, expand, etc. based on flags), allocates row pointers, reads all image data, then reads post-IDAT chunks. The transform flags are standard libpng PNG_TRANSFORM_* values. |
| 0x00E74510 | 779 | png__read_row | libpng: Reads and processes a single row of PNG image data. Handles interlace pass tracking, reads IDAT data, applies PNG row filter (sub/up/average/paeth), applies read transforms, handles interlace row expansion and combination with previous pass data. Calls the row callback if set. |
| 0x00E74840 | 141 | png__read_rows | libpng: Reads multiple rows of PNG image data. Iterates param_4 times calling png__read_row. Supports separate row and display row arrays (either can be NULL). Advances row pointers after each call. |
| 0x00E748D0 | 55 | png__read_update_info | libpng: Updates the png_info struct to reflect the effect of applied transforms. Must be called after setting transforms but before reading rows. Starts the row processing if not already started, then updates the info struct fields. Warns if called after rows have already been read. |
| 0x00E74910 | 21 | png__set_strip_alpha_00e74910 | Sets the strip alpha flag on a PNG read structure. If param_1 is non-null, stores param_2 at offset 0x1C4 to configure alpha channel stripping behavior. |
| 0x00E74930 | 41 | png__start_read_image | libpng: Starts PNG image row reading. If not already started (flag 0x40 not set), calls png_read_start_row to initialize. If already started, logs a warning or error based on mode flags. |
| 0x00E74960 | 91 | png__image_determine_encoding | libpng: Determines the encoding mode for simplified API image reading based on gamma. Mode 4: gamma insignificant (pass through), mode 3: gamma needs correction (computes reciprocal), mode 1: gamma below threshold (sRGB). |
| 0x00E749C0 | 33 | png__app_warning_or_error | libpng: Issues a warning if mode flag 0x400000 is set, otherwise issues a fatal error. Used when the application calls a function in an unexpected state (e.g., calling read_update_info after rows started). |
| 0x00E749F0 | 33 | png__app_error_or_warning | libpng: Issues a warning if mode flag 0x200000 is set, otherwise issues a fatal error. Similar to png__app_warning_or_error but checks different flag bit. |
| 0x00E74A20 | 86 | png__chunk_benign_error | libpng: Reports a benign chunk error. Behavior depends on mode flags: if 0x100000 set, issues warning (with chunk prefix if inside a chunk); otherwise issues fatal error (with chunk prefix if inside a chunk and flag 0x8000 is set). |
| 0x00E74A80 | 33 | png__chunk_error_or_warning | libpng: Reports a chunk error. If mode flag 0x100000 is set, issues a chunk warning; otherwise issues a fatal chunk error. Used for errors that may be non-fatal in some modes. |
| 0x00E74AB0 | 56 | png__formatted_chunk_error | libpng: Formats a chunk error message with the current chunk name prefix and issues a fatal error. Prepends the chunk tag to the error message using png__format_error_string. |
| 0x00E74AF0 | 71 | png__chunk_report | libpng: Reports a chunk-related issue at a given severity level. Level 0: error or warning (via app_error), level 1: warning or error (via app_warning), level 2+: chunk warning if inside chunk (flag 0x8000 set), otherwise chunk error. |
| 0x00E74B40 | 78 | png__formatted_chunk_warning | libpng: Formats a chunk warning message with the current chunk name prefix and issues a warning. Prepends the chunk tag to the message using png__format_error_string if png_ptr is valid. |
| 0x00E74B90 | 76 | png__default_error_handler | libpng: Default error handler. Prints "libpng error: <message>" to stderr, calls abort via png_longjmp. Uses __debugbreak (int 3) as fallback if longjmp fails. Replaces NULL message with "undefined". |
| 0x00E74BE0 | 56 | png__default_warning_handler | libpng: Default warning handler. Prints "libpng warning: <message>" followed by a newline to stderr. |
| 0x00E74C20 | 37 | png__error | libpng: Issues a fatal PNG error. Calls the user error handler if set (offset 0x4C), then falls through to the default error handler. This function never returns - it either longjmps or aborts. |
| 0x00E74C50 | 110 | png__fixed_point_overflow_error | libpng: Issues a "fixed point overflow" fatal error with an appended context message. Copies the context string (up to 0xC3 chars) after the overflow prefix and calls png__error. |
| 0x00E74CC0 | 273 | png__format_error_string | libpng: Formats an error/warning string with the current chunk name prefix. Converts the 4-byte chunk tag at offset 0x11C to printable form (non-alpha bytes shown as [XX]), appends ": " and the error message. Output buffer receives "XXXX: message". |
| 0x00E74DE0 | 297 | png__format_number | libpng: Formats an unsigned integer into a string buffer (right-to-left). Supports decimal (mode 1-2), hexadecimal (mode 3-4), and fixed-point decimal with 5 fractional digits (mode 5). Modes 2,4 pad to minimum 2 characters. Returns pointer to the start of the formatted string. |
| 0x00E74F20 | 219 | png__formatted_warning | libpng: Formats a warning message with parameter substitution. '@1' through '@8' in the format string are replaced with 32-byte string parameters from the params array. Builds the result into a 192-byte buffer and calls png__warning. |
| 0x00E75000 | 136 | png__safe_execute_jmpbuf_cleanup | libpng: Cleans up the setjmp/longjmp error handling context. If a different jmp_buf was installed (not the struct itself), frees it via a temporary setjmp context. Clears the longjmp callback, jmp_buf pointer, and error return address. |
| 0x00E75090 | 17 | png__get_error_ptr | libpng: Returns the user-defined error pointer stored at offset 0x54 in the png_struct. Returns 0 if png_ptr is NULL. |
| 0x00E750B0 | 41 | png__longjmp | libpng: Performs a longjmp to exit the current PNG operation. Calls the longjmp function pointer at offset 0x40 with the jmp_buf at offset 0x44. If longjmp is not set up, calls ExitProcess(0) as fallback. |
| 0x00E750E0 | 94 | png__image_error_callback | libpng: Error callback for the simplified API. Gets the png_image from the error pointer, copies the error message, sets the error flag (bit 2), then longjmps back to the safe execute point. Aborts if longjmp fails, prepending "bad longjmp: " to the message. |
| 0x00E75140 | 143 | png__safe_execute | libpng: Safely executes a callback function with error recovery. Sets up a setjmp point, installs it in the control struct, calls the callback. On error (longjmp), frees the image. Returns callback result on success, 0 on error. |
| 0x00E751D0 | 42 | png__image_warning_callback | libpng: Warning callback for the simplified API. Stores the first warning message in the image's message buffer (offset 0x20, max 0x40) and sets warning flag (bit 1). Ignores subsequent warnings if flags are already set. |
| 0x00E75200 | 61 | png__safe_strcpy | libpng: Safe string copy with bounds checking. Copies from param_4 to param_1 starting at offset param_3, up to param_2-1 characters. Always null-terminates. Returns void but effectively acts as strlcpy into a buffer region. |
| 0x00E75240 | 30 | png__set_error_fn | libpng: Sets the error handling functions and user error pointer. Stores error_ptr at offset 0x54, error_fn at offset 0x4C, and warning_fn at offset 0x50 in the png_struct. |
| 0x00E75260 | 127 | png__set_longjmp_fn | libpng: Sets the longjmp function and allocates the jmp_buf. If jmp_buf not yet allocated and size > 0x40, allocates from heap; otherwise uses inline buffer at png_struct base. Validates size consistency on subsequent calls. Returns pointer to jmp_buf or 0 on failure. |
| 0x00E752E0 | 90 | png__warning | libpng: Issues a PNG warning. If the message starts with '#', skips the numeric prefix (up to 15 chars before a space). Calls user warning handler if set (offset 0x50), otherwise calls the default warning handler. |
| 0x00E75340 | 43 | png__warning_parameter_set | libpng: Sets a string parameter for formatted warnings. param_2 (1-8) selects which of 8 parameter slots (each 32 bytes) to write the string value into. |
| 0x00E75370 | 98 | png__warning_parameter_signed | libpng: Sets a signed integer warning parameter. Formats the number using png__format_number, prepends '-' for negative values, and stores in the specified parameter slot. |
| 0x00E753E0 | 68 | png__warning_parameter_unsigned | libpng: Sets an unsigned integer warning parameter. Formats the number using png__format_number and stores in the specified parameter slot. |
| 0x00E75430 | 122 | png__fixed_from_double | libpng: Converts a double-precision gamma value to PNG fixed-point integer. If value is between 0 and a threshold, multiplies by 100000. Rounds with floor(x+0.5). Fatal "gamma value" overflow error if result exceeds int range. |
| 0x00E754B0 | 92 | png__do_chop_16to8 | libpng: Chops 16-bit samples down to 8-bit by keeping only the high byte. Copies every other byte, then updates the row info to reflect 8-bit depth. |
| 0x00E75510 | 4367 | png__do_read_transformations_background | libpng: Applies background compositing and gamma correction during row read. Handles all color types (gray 1/2/4/8/16 bit, RGB 8/16 bit, gray+alpha 8/16, RGBA 8/16). Replaces transparent pixels with background color and applies gamma tables for correction. Very large function (~4.3KB) handling all pixel format combinations. |
| 0x00E76670 | 232 | png__do_encode_alpha | libpng: Encodes/transforms alpha channel values through gamma table. For 8-bit: applies background gamma table lookup. For 16-bit: applies 16-bit gamma table lookup. Only processes color types with alpha (4, 6). Warns on unexpected call conditions. |
| 0x00E76760 | 1067 | png__do_expand_tRNS | libpng: Expands transparency (tRNS) data into a full alpha channel. For grayscale: expands 1/2/4-bit to 8-bit first, then adds alpha. For RGB: adds alpha channel based on tRNS color match. Handles both 8-bit and 16-bit samples. Updates row info color type and channel count. |
| 0x00E76B90 | 75 | png__do_expand_16 | libpng: Expands 8-bit samples to 16-bit by duplicating each byte. Only applies to non-palette color types at 8-bit depth. Updates row info to reflect 16-bit depth. |
| 0x00E76BE0 | 621 | png__do_expand_palette | libpng: Expands palette-indexed pixels to RGB or RGBA. First unpacks sub-byte (1/2/4-bit) indices to 8-bit. Then looks up each index in the palette to get RGB values, optionally adding alpha from tRNS data. Updates color type to RGB(A) and adjusts row info. |
| 0x00E76E50 | 992 | png__do_gamma_correction | libpng: Applies gamma correction to pixel data using precomputed gamma tables. Handles all color types (gray 2/4/8/16 bit, RGB 8/16, gray+alpha 8/16, RGBA 8/16). For sub-byte gray (2/4 bit), applies gamma per packed pixel. Uses 8-bit lookup table or 16-bit 2D table depending on depth. |
| 0x00E77250 | 435 | png__do_gray_to_rgb | libpng: Converts grayscale pixels to RGB by triplicating each sample. Handles gray (type 0) and gray+alpha (type 4) for both 8-bit and 16-bit depths. Works right-to-left to expand in-place. Updates color type to include RGB flag. |
| 0x00E77410 | 366 | png__do_quantize | libpng: Quantizes RGB/RGBA pixels to palette indices. For RGB (type 2) and RGBA (type 6): looks up each pixel in a quantize table using (R&F8)<<5\|(G&F8)<<2\|(B>>3) as index. For palette (type 3): remaps indices through a translation table. Only works at 8-bit depth. |
| 0x00E77580 | 677 | png__do_read_filler | libpng: Adds a filler byte/word to pixel data (e.g., adding alpha=0xFF to RGB to make RGBA). Handles gray and RGB at both 8-bit and 16-bit. The filler can be prepended (param_4 & 0x80) or appended based on flags. Expands in-place right-to-left. Updates channel count and row info. |
| 0x00E77830 | 145 | png__do_read_invert_alpha | libpng: Inverts alpha channel values (alpha = ~alpha). Handles color types 6 (RGBA) and 4 (gray+alpha) at both 8-bit and 16-bit depth. Works backwards through the row data. |
| 0x00E778D0 | 264 | png__do_read_swap_alpha | libpng: Swaps alpha channel position in pixel data. For RGBA: moves alpha from last to first position (RGBA -> ARGB). For gray+alpha: swaps GA -> AG. Handles both 8-bit and 16-bit. Works backwards through row. |
| 0x00E779E0 | 1080 | png__do_read_transformations | Applies all configured PNG read transformations to a row of pixels. Checks transformation flags at offset 0x7C and applies in order: palette expansion, tRNS expansion, strip alpha, RGB to gray, gray to RGB, background compositing, gamma correction, scale 16-to-8, chop 16-to-8, quantize, expand 16, invert, swap alpha, shift, unpack, BGR swap, packswap, filler, swap bytes, and user transform callback. Updates row info after each applicable transformation. |
| 0x00E77E20 | 1031 | png__do_rgb_to_gray | Converts RGB pixel data to grayscale using configurable weights. Handles 8-bit and 16-bit color depths, with and without alpha channel. Uses red/green/blue weighting coefficients from the PNG struct (offsets 0x24E, 0x250). Supports both direct computation and gamma-corrected lookup table paths. Returns 1 if any non-gray pixels were found, 0 otherwise. |
| 0x00E78230 | 96 | png__do_scale_16to8 | libpng: Scales 16-bit samples down to 8-bit with proper rounding (not just truncation). Uses the formula: out = hi + ((lo - hi + 128) * 65535 >> 24). Updates row info to 8-bit depth. |
| 0x00E78290 | 359 | png__do_unpack | libpng: Unpacks sub-byte samples (1, 2, or 4-bit) to one sample per byte. Expands in-place right-to-left to avoid overwriting. For 1-bit: extracts each bit. For 2-bit: extracts 2-bit values. For 4-bit: extracts nibbles. Updates row info to 8-bit depth. |
| 0x00E78400 | 514 | png__do_shift | libpng: Applies sBIT-based bit depth reduction by right-shifting samples. Computes shift amounts from the difference between actual bit depth and sBIT values for each channel. Handles 2/4/8/16-bit samples across all non-palette color types. Skips if no significant shift is needed. |
| 0x00E78630 | 59 | png__gamma_not_sRGB | libpng: Returns 1 if the product of two gamma values is significantly different from sRGB (i.e., the combined gamma correction is meaningful). Returns 0 if the result is close to unity or calculation overflows. |
| 0x00E78670 | 328 | png__init_read_transformations | libpng: Initializes read transform state. Processes tRNS data to determine alpha handling, sets up background color from palette if needed, and optionally inverts tRNS alpha data when both tRNS and background are active in non-alpha-strip mode. Handles the tRNS inversion in 64-byte blocks for performance. |
| 0x00E787C0 | 2769 | png__init_gamma_and_background | libpng: Main initialization of gamma correction and background compositing for read transforms. Sets up gamma tables, computes background gamma correction, handles palette gamma for indexed images, applies sBIT shift to palette, and configures all gamma-related transform flags. Called during png_read_start_row. |
| 0x00E792A0 | 214 | png__init_non_palette_transforms | libpng: Initializes transform state for non-palette images. Clears alpha mode flags if no alpha channel, disables tRNS if not present. Expands background/transparent values for sub-8-bit gray (1/2/4 bit to 8-bit range) based on bit depth. |
| 0x00E79380 | 484 | png__read_transform_info | libpng: Updates png_info to reflect the effects of applied read transforms. Adjusts color type (expand palette to RGB/RGBA, strip alpha, add filler), bit depth (16->8, expand to 16), channel count, and pixel size. Updates background color, gamma, and row byte count. Called by png_read_update_info. |
| 0x00E79570 | 82 | png__set_transform_check | libpng: Validates that a read transform can be set. Errors if already past start_read_image (flag 0x40 set). If param_2 is nonzero, also requires IHDR to have been read (flag 0x01). Sets the "transform set" flag (0x4000). Returns 1 if valid to set, 0 otherwise. |
| 0x00E795D0 | 41 | png__set_alpha_mode_double | libpng: Sets alpha mode with gamma as a double. Converts double gamma to fixed-point via png__fixed_from_double, then calls png__set_alpha_mode_fixed. |
| 0x00E79600 | 286 | png__set_alpha_mode_fixed | libpng: Sets the alpha compositing mode and output gamma. Mode 0: default, mode 1: associated alpha (gamma=1.0), mode 2: premultiplied alpha with gamma encoding, mode 3: linear alpha. Validates gamma range (1000-10000000). Sets background to black for modes 1-2 and configures gamma transform flags. |
| 0x00E79730 | 52 | png__set_background_double | libpng: Sets background color with gamma as a double. Converts double gamma to fixed-point, then calls png__set_background_fixed. |
| 0x00E79770 | 143 | png__set_background_fixed | libpng: Sets the background color for alpha compositing. Copies the background RGB values, stores gamma and background type. param_3 must be nonzero (known background). param_4 controls whether to expand 16-bit. Sets transform flags 0x80 (background) and related mode bits. |
| 0x00E79800 | 66 | png__set_crc_action | libpng: Sets how CRC errors are handled for critical and ancillary chunks. For each, values 2=warn, 3=ignore CRC, 4=ignore CRC silently, 5=keep current. Critical chunks warn on attempt to discard. Controls flag bits 0x400/0x800 (critical) and 0x100/0x200 (ancillary). |
| 0x00E798C0 | 32 | png__set_expand | libpng: Enables the expand transform. Sets transform flags 0x1000 (expand) and 0x2000000 (expand tRNS to alpha). This expands palette to RGB, grayscale to 8-bit, and adds alpha from tRNS. |
| 0x00E798E0 | 32 | png__set_expand_gray_1_2_4_to_8 | libpng: Enables expand of 1/2/4-bit grayscale to 8-bit. Also sets the tRNS-to-alpha expansion flag (0x2000000). Sets transform flags 0x1200 \| 0x2000000. |
| 0x00E79900 | 32 | png__set_expand_palette_to_rgb | libpng: Enables palette-to-RGB expansion. Sets transform flag 0x1000. |
| 0x00E79920 | 65 | png__set_gamma_double | libpng: Sets screen and file gamma values from doubles. Converts both to fixed-point and calls png__set_gamma_fixed. |
| 0x00E79970 | 102 | png__set_gamma_fixed | libpng: Sets screen gamma and file gamma for gamma correction. Validates both values (file gamma > 0, screen gamma > 0). Stores file gamma at offset 0x2C8, screen gamma at 0x18C. Sets the gamma-initialized flag (bit 1 at offset 0x312). |
| 0x00E799E0 | 41 | png__set_gray_to_rgb | libpng: Enables grayscale-to-RGB conversion. Also enables palette expansion (0x1000). Sets transform flag 0x4000 for the actual gray-to-RGB conversion. |
| 0x00E79A10 | 32 | png__set_tRNS_to_alpha | libpng: Enables tRNS transparency to alpha channel expansion. Sets transform flags 0x1000 (expand) and 0x2000000 (tRNS to alpha). |
| 0x00E79A30 | 1887 | png__set_quantize | libpng: Sets up color quantization (palette reduction). If no histogram provided, uses a median-cut algorithm to reduce palette from param_3 to param_4 entries. If histogram provided, sorts by frequency and remaps. Builds a 32K-entry quantize lookup table mapping 15-bit RGB to palette index. Sets transform flag 0x40. |
| 0x00E7A190 | 21 | png__set_read_user_chunk_fn | libpng: Sets a user callback for handling unknown chunks. Sets flag 0x100000 in mode word and stores callback pointer at offset 0x64. |
| 0x00E7A1B0 | 78 | png__set_rgb_to_gray_double | libpng: Sets RGB-to-gray conversion with double-precision coefficients. Converts the red and green coefficients to fixed-point, then calls png__set_rgb_to_gray_fixed. |
| 0x00E7A200 | 240 | png__set_rgb_to_gray_fixed | libpng: Sets up RGB-to-grayscale conversion with fixed-point coefficients. Error action: 1=error+no output, 2=only flag, 3=no error. Red/green coefficients must sum to <= 100000 (1.0). Stores coefficients as fixed-point at offsets 0x24E/0x250. Defaults to ITU-R 601 (0x1B38/0x5B8A) if both zero. Also enables palette expansion for indexed images. |
| 0x00E7A300 | 32 | png__set_strip_16 | libpng: Enables stripping 16-bit channels down to 8-bit. Sets transform flag 0x4000000. |
| 0x00E7A320 | 32 | png__set_strip_alpha | libpng: Enables stripping the alpha channel from output. Sets transform flag 0x400. |
| 0x00E7A340 | 32 | png__set_strip_alpha_no_filler | libpng: Strips alpha without adding filler. Sets transform flag 0x40000. |
| 0x00E7A360 | 32 | png__set_expand_with_tRNS | libpng: Enables expand with tRNS to alpha. Sets flags 0x1000 (expand) and 0x2000000 (tRNS to alpha). |
| 0x00E7A380 | 78 | png__resolve_gamma_constant | libpng: Resolves symbolic gamma constants to fixed-point values. -1/-100000 = sRGB (45455 or 220000), -2/-50000 = Mac (65909 or 153132). Sets sRGB flag for sRGB constants. |
| 0x00E7A3D0 | 214 | png__do_bgr | Swaps RGB byte order to BGR (and vice versa) for PNG pixel data. Handles both 8-bit and 16-bit depths, with and without alpha channel. For 8-bit: swaps bytes 0 and 2 in each pixel. For 16-bit: swaps byte pairs 0-1 and 4-5 in each pixel. |
| 0x00E7A4B0 | 354 | png__do_check_palette_indexes | libpng: Scans row data for palette index values exceeding palette size. Tracks maximum index at offset 0x148. Only checks palette (type 3) images with 1/2/4/8-bit depth when palette count is less than max for bit depth. |
| 0x00E7A640 | 197 | png__do_invert | libpng: Bitwise inverts pixel data. For gray (type 0): inverts all bytes with 64-byte loop unrolling. For gray+alpha (type 4): inverts only the gray channel bytes (8-bit or 16-bit), leaving alpha unchanged. |
| 0x00E7A710 | 102 | png__do_packswap | libpng: Reverses bit order within bytes for sub-byte pixel packing (1/2/4-bit). Uses lookup tables to swap MSB-first to LSB-first ordering and vice versa. |
| 0x00E7A780 | 399 | png__do_strip_channel | libpng: Strips a channel from pixel data (removes alpha or filler). For 2-channel gray+alpha and 4-channel RGBA, removes the specified channel. param_3 controls which channel to remove (0=first, nonzero=last). Updates color type, channels, and row bytes. |
| 0x00E7A910 | 54 | png__do_swap_bytes | libpng: Swaps byte order for 16-bit samples (big-endian to little-endian). Iterates through all sample bytes swapping adjacent pairs. |
| 0x00E7A950 | 22 | png__get_interlace_type | Returns the interlace type from a PNG info struct at offset 0x151. Returns 8 if the struct pointer is null. |
| 0x00E7A970 | 23 | png__get_user_chunk_ptr | libpng: Returns the user chunk callback pointer from offset 0x118 in the png_struct. Returns -1 (0xFFFFFFFF) if the struct pointer is null. Note: this is NOT the I/O pointer (which is at offset 0x60). |
| 0x00E7A990 | 17 | png__get_user_data | Returns user data pointer from PNG struct at offset 0x6C. Returns 0 if struct is null. |
| 0x00E7A9B0 | 47 | png__set_add_alpha | Configures PNG to add an alpha channel filler. Calls png__set_filler, then if filler flag (0x8000) is already set, also sets the alpha expansion flag (0x1000000). |
| 0x00E7A9E0 | 16 | png__set_bgr | Enables BGR byte order transformation by setting flag 0x1 in the transformation flags at offset 0x7C. |
| 0x00E7A9F0 | 146 | png__set_filler | Configures PNG filler byte for expanding grayscale or RGB data. Validates color type (must be grayscale or RGB, not paletted). Sets filler value at offset 0x15E, enables filler transformation flag (0x8000), and configures filler position (before=0x80 flag set, after=cleared) based on param_3. |
| 0x00E7AA90 | 37 | png__set_interlace_handling | Enables interlace handling for PNG reading. If interlaced (field 0x150 != 0), sets interlace flag (0x2) and returns 7 (number of Adam7 passes). Returns 1 for non-interlaced images. |
| 0x00E7AAC0 | 19 | png__set_invert_alpha | Enables alpha channel inversion by setting flag 0x80000 in the transformation flags at offset 0x7C. |
| 0x00E7AAE0 | 16 | png__set_invert_mono | Enables monochrome inversion by setting flag 0x20 in the transformation flags at offset 0x7C. |
| 0x00E7AAF0 | 32 | png__set_packing | Enables pixel packing transformation. If bit depth < 8, sets packing flag (0x4) and overrides bit depth to 8 at offset 0x155. |
| 0x00E7AB10 | 28 | png__set_packswap | Enables pack swap transformation for sub-byte pixels (bit depth < 8). Sets flag 0x10000 in transformation flags at offset 0x7C. |
| 0x00E7AB30 | 36 | png__set_shift | Enables bit shifting transformation. Sets shift flag (0x8) and copies 5-byte shift data (sBIT structure) from param_2 to offset 0x1AD in the PNG struct. |
| 0x00E7AB60 | 25 | png__set_swap | Enables byte swap transformation for 16-bit depth images. Sets flag 0x10 in transformation flags at offset 0x7C, only if bit depth is 16. |
| 0x00E7AB80 | 19 | png__set_swap_alpha | Enables alpha channel swap (RGBA to ARGB) by setting flag 0x20000 in the transformation flags at offset 0x7C. |
| 0x00E7ABA0 | 61 | png__set_user_transform_info | Sets user-defined transform info on the PNG struct. Stores user data at 0x6C, user depth at 0x70, user channels at 0x71. Warns if called after read has started (filler flag 0x8000 set and flag 0x40 set). |
| 0x00E7ABE0 | 49 | png__default_read_data_file | Default file-based PNG read callback. Reads param_3 bytes into param_2 from the FILE* at offset 0x60 in the PNG struct. Triggers a PNG error ("Read Error") if the read count doesn't match the requested size. |
| 0x00E7AC20 | 30 | png__default_read_data | Default PNG read data callback. Calls the read function pointer at offset 0x5C. If the function pointer is null, triggers a PNG error with "Call to NULL read function". |
| 0x00E7AC40 | 73 | png__set_read_fn | Sets the PNG read function callback. Stores I/O pointer at offset 0x60, read function at 0x5C (defaults to png__default_read_data if null). Clears write function at 0x58 with a warning if it was set. Clears progressive read flag at 0x17C. |
| 0x00E7AC90 | 26 | png__pixels_to_inches_fixed | libpng: Converts pixels-per-meter to a fixed-point representation related to inches. Computes (param_2 * 500) / 127, which equals param_2 * 3.937 (the meters-to-inches conversion factor * 100). Delegates to png__muldiv_warn for overflow-safe computation. |
| 0x00E7ACB0 | 166 | png_get_IHDR | libpng: png_get_IHDR - extracts image header info (width, height, bit_depth, color_type, interlace, compression, filter) from png_info struct. Calls FUN_00e6dee0 to validate/process the values. Returns 1 on success, 0 if png_ptr or info_ptr is NULL. |
| 0x00E7AD60 | 54 | png_get_oFFs | libpng: png_get_oFFs - retrieves image offset (x_offset, y_offset, unit_type) from png_info. Checks flag bit 0x8. Returns 8 on success, 0 if not available. |
| 0x00E7ADA0 | 47 | png_get_sCAL_s | libpng: png_get_sCAL_s - retrieves sCAL chunk data as string pointer from png_info. Checks flag bit 0x20. Returns pointer to scale data at info+0xaa. Returns 0x20 on success. |
| 0x00E7ADD0 | 25 | png_get_channels | libpng: png_get_channels - returns the number of channels from png_info at offset 0x18. Returns 0 if either pointer is NULL. |
| 0x00E7ADF0 | 245 | png_get_cHRM | libpng: png_get_cHRM - retrieves chromaticity values (white_x, white_y, red_x, red_y, green_x, green_y, blue_x, blue_y) as doubles from png_info. Checks sBIT flag (bit 2). Multiplies raw ints by DAT_011bc300 scale factor. Returns 4 on success. |
| 0x00E7AEF0 | 269 | png_get_cHRM_XYZ | libpng: png_get_cHRM_XYZ - retrieves CIE XYZ chromaticity values (9 doubles: red_X/Y/Z, green_X/Y/Z, blue_X/Y/Z) from png_info. Checks sBIT flag (bit 2). Multiplies raw ints by DAT_011bc300. Returns 4 on success. |
| 0x00E7B000 | 145 | png_get_cHRM_XYZ_fixed | libpng: png_get_cHRM_XYZ_fixed - retrieves CIE XYZ chromaticity values as fixed-point integers (9 values: red_X/Y/Z, green_X/Y/Z, blue_X/Y/Z) from png_info offsets 0x4c-0x6c. Checks sBIT flag (bit 2). Returns 4 on success. |
| 0x00E7B0A0 | 129 | png_get_cHRM_fixed | libpng: png_get_cHRM_fixed - retrieves chromaticity values as fixed-point integers (white_x, white_y, red_x, red_y, green_x, green_y, blue_x, blue_y) from png_info offsets 0x44,0x48,0x2c-0x40. Checks sBIT flag (bit 2). Returns 4 on success. |
| 0x00E7B130 | 25 | png_get_filter_type | libpng: png_get_filter_type - returns the filter type byte from png_info at offset 0x1d. Returns 0 if pointers are NULL. |
| 0x00E7B150 | 22 | png_get_header_ver | libpng: png_get_header_ver - returns the PNG header version string pointer from png_struct at offset 0x284. Returns 0/NULL if png_ptr is NULL. |
| 0x00E7B170 | 22 | png_get_header_version | libpng: png_get_header_version - returns the PNG header version string pointer from png_struct at offset 0x288. Returns 0/NULL if png_ptr is NULL. |
| 0x00E7B190 | 25 | png_get_color_type | libpng: png_get_color_type - returns the color type byte from png_info at offset 0x19. Returns 0 if pointers are NULL. |
| 0x00E7B1B0 | 37 | png_get_rowbytes | libpng: png_get_rowbytes - returns the number of bytes per row. If flag 0x8000 is set, reads from png_struct+0x2ac (transformed rowbytes), otherwise from png_struct+0xc0. Returns 0 if png_ptr is NULL. |
| 0x00E7B1E0 | 25 | png_get_compression_type | libpng: png_get_compression_type - returns the compression type byte from png_info at offset 0x1a. Returns 0 if pointers are NULL. |
| 0x00E7B200 | 23 | png_get_eXIf_deprecated | libpng: png_get_eXIf (deprecated) - warns that png_get_eXIf does not work and to use png_get_eXIf_1 instead. Always returns 0. |
| 0x00E7B220 | 65 | png_get_eXIf_1 | libpng: png_get_eXIf_1 - retrieves eXIf (EXIF) chunk data from png_info. Checks flag bit 0x10000. Returns num_exif and exif data pointer. Returns 0x10000 on success. |
| 0x00E7B270 | 25 | png_get_interlace_type | libpng: png_get_interlace_type - returns the interlace type byte from png_info at offset 0x1b. Returns 0 if pointers are NULL. |
| 0x00E7B290 | 61 | png_get_gAMA | libpng: png_get_gAMA - retrieves gamma value as double from png_info. Checks flag bit 0x1 (gAMA present). Multiplies fixed-point int at offset 0x28 by DAT_011bc300. Returns 1 on success. |
| 0x00E7B2D0 | 45 | png_get_gAMA_fixed | libpng: png_get_gAMA_fixed - retrieves gamma value as fixed-point integer from png_info at offset 0x28. Checks flag bit 0x1 (gAMA present). Returns 1 on success. |
| 0x00E7B300 | 48 | png_get_pHYs | libpng: png_get_pHYs - retrieves physical pixel dimensions (res_x) from png_info at offset 0xd8. Checks flag bit 0x40. Returns 0x40 on success, 0 if not available. |
| 0x00E7B330 | 118 | png_get_iCCP | libpng: png_get_iCCP - retrieves ICC color profile data from png_info. Checks flag bit 0x1000 (iCCP present). Returns profile name count at offset 0x74, profile data pointer at 0x78, and first 4 bytes of profile data. param_4 (compression) always set to 0. Returns 0x1000 on success, 0 if not available. |
| 0x00E7B3B0 | 25 | png_get_image_height | libpng: png_get_image_height - returns the image height from png_info at offset 0x4. Returns 0 if pointers are NULL. |
| 0x00E7B3D0 | 24 | png_get_image_width | libpng: png_get_image_width - returns the image width from png_info at offset 0x0. Returns 0 if pointers are NULL. |
| 0x00E7B3F0 | 25 | png_get_bit_depth | libpng: png_get_bit_depth - returns the bit depth byte from png_info at offset 0x1c. Returns 0 if pointers are NULL. |
| 0x00E7B410 | 14 | png_get_io_ptr | libpng: png_get_io_ptr - returns the I/O pointer from png_struct at offset 0x11c. Used to retrieve custom I/O state. |
| 0x00E7B420 | 14 | png_get_user_chunk_ptr | libpng: png_get_user_chunk_ptr - returns the user chunk data pointer from png_struct at offset 0x2b0. |
| 0x00E7B430 | 88 | png_get_tRNS | libpng: png_get_tRNS - retrieves transparency data (num_trans, trans_alpha, trans_color) from png_info. Checks flag bit 0x100. Returns 0x100 on success. |
| 0x00E7B490 | 166 | png_get_sPLT | libpng: png_get_sPLT - retrieves suggested palette data (7 fields: name, depth, entries, nentries, etc.) from png_info. Checks flag bit 0x400. Returns 0x400 on success. |
| 0x00E7B540 | 86 | png_get_pHYs_00e7b540 | libpng: png_get_pHYs - retrieves physical pixel dimensions (x_ppu, y_ppu, unit_type) from png_info. Checks flag bit 0x80 (PNG_INFO_pHYs). Returns 0x80 on success. Was misnamed png_get_tIME. |
| 0x00E7B5A0 | 225 | png_get_pHYs_dpi | libpng: Extended pHYs retrieval - gets x_ppu, y_ppu, unit_type from png_info. When unit_type==1 (meters), recalculates x/y PPU using DPI conversion. Was misnamed png_get_tIME_with_defaults. |
| 0x00E7B690 | 29 | png_get_chunk_malloc_max | libpng: Returns the chunk malloc max limit from png_struct at offset 0x148. Returns -1 (0xFFFFFFFF) if png_ptr or info_ptr is NULL. Was misnamed png_get_unknown_chunks (that function reads from info_ptr, not png_struct). |
| 0x00E7B6B0 | 102 | png_get_pixel_aspect_ratio | libpng: png_get_pixel_aspect_ratio - calculates pixel aspect ratio as float from pHYs data (y_ppu/x_ppu). Checks flag bit 0x80 and validates x_ppu != 0. Returns 0.0 if not available. |
| 0x00E7B720 | 89 | png_get_pixel_aspect_ratio_fixed | libpng: png_get_pixel_aspect_ratio_fixed - calculates pixel aspect ratio as fixed-point from pHYs data. Uses FUN_00e701c0 for fixed-point division (y_ppu * 100000 / x_ppu). Returns 0 if not available. |
| 0x00E7B780 | 25 | png_get_pixels_per_inch | libpng: png_get_pixels_per_inch - returns pixels per inch by calling png_get_pixels_per_meter then converting via png_ppi_from_ppm. Was misnamed png_get_pixels_per_meter. |
| 0x00E7B7A0 | 49 | png_get_pixels_per_meter | libpng: png_get_pixels_per_meter - returns pixels per meter only when x_ppu == y_ppu and unit_type==1 (meters). Returns x_ppu value. Was misnamed png_get_x_pixels_per_meter. |
| 0x00E7B7E0 | 22 | png_get_interlace_pass | libpng: png_get_interlace_pass - returns current interlace pass number from png_struct at offset 0x24c. Returns 0 if png_ptr is NULL. |
| 0x00E7B800 | 25 | png_get_palette_max | libpng: png_get_palette_max - returns the max palette index from png_info at offset 0xc. Returns 0 if pointers are NULL. |
| 0x00E7B820 | 28 | png_get_num_text | libpng: png_get_num_text - returns the number of text chunks from png_info at offset 0x114. Returns 0 if pointers are NULL. |
| 0x00E7B840 | 47 | png_get_sBIT | libpng: png_get_sBIT - retrieves significant bits info pointer from png_info at offset 0x94. Checks flag bit 0x2. Returns 2 on success. |
| 0x00E7B870 | 86 | png_get_sCAL | libpng: png_get_sCAL - retrieves physical scale data (unit, width, height as doubles via atof) from png_info. Checks flag bit 0x4000. Returns 0x4000 on success. |
| 0x00E7B8D0 | 123 | png_get_sCAL_fixed | libpng: png_get_sCAL_fixed - retrieves physical scale data as fixed-point values. Converts width/height strings via atof then png__float_to_fixed_point. Checks flag bit 0x4000. Returns 0x4000 on success. |
| 0x00E7B950 | 70 | png_get_sCAL_s_00e7b950 | libpng: png_get_sCAL_s - retrieves sCAL unit type and raw string pointers for width/height from png_info. Checks flag bit 0x4000. Returns 0x4000 on success. Was png_get_sCAL_s_raw. |
| 0x00E7B9A0 | 43 | png_get_unknown_chunks | libpng: png_get_unknown_chunks - retrieves unknown chunk list pointer (offset 0x100) and count (offset 0x104) from png_info. Was misnamed png_get_unknown_chunk_data. |
| 0x00E7B9D0 | 49 | png_get_num_palette | libpng: png_get_num_palette - returns the number of palette entries from png_info at offset 0x70 (ushort). Checks flag bit 0x800. Returns 0x800 on success. |
| 0x00E7BA10 | 25 | png_get_signature | libpng: png_get_signature - returns pointer to PNG signature bytes at png_info + 0x20. Returns NULL if pointers are NULL. |
| 0x00E7BA30 | 50 | png_get_bKGD | libpng: png_get_bKGD - retrieves background color pointer from png_info at offset 0x8c. Checks flag bit 0x200. Returns 0x200 on success. |
| 0x00E7BA70 | 130 | png_get_PLTE | libpng: png_get_PLTE - retrieves palette data from png_info. For color_type 3: returns palette pointer at 0x9c and palette color at 0xa0. For others: returns palette color at 0xa0. Sets num_palette from offset 0x16. Checks flag bit 0x10. Returns 0x10 on success. |
| 0x00E7BB00 | 71 | png_get_text | libpng: png_get_text - retrieves text chunk array from png_info. Returns text_ptr at 0x88 and num_text from 0x80. Returns count on success, 0 if none. |
| 0x00E7BB50 | 43 | png_get_hIST | libpng: png_get_hIST - retrieves histogram data pointer and count from png_info at offsets 0xf8/0xfc. Returns count on success, 0 if not available. |
| 0x00E7BB80 | 22 | png_get_compression_buffer_size | libpng: png_get_compression_buffer_size - returns the compression buffer size from png_struct at offset 0x238. Returns 0 if png_ptr is NULL. |
| 0x00E7BBA0 | 22 | png_get_palette_count | libpng: Returns the palette entry count from png_info struct at offset 0x280. Returns 0 if struct is null. Fixed from png__get_palette_count (wrong double-underscore). |
| 0x00E7BBC0 | 22 | png_get_user_width_max | libpng: png_get_user_width_max - returns the maximum user width from png_struct at offset 0x27c. Returns 0 if png_ptr is NULL. |
| 0x00E7BBE0 | 28 | png_get_valid | libpng: png_get_valid - tests if specific chunk flags are set in png_info valid field at offset 0x8. Returns the masked flag bits, 0 if pointers are NULL. |
| 0x00E7BC00 | 50 | png_get_x_offset_inches | libpng: png_get_x_offset_inches - returns x offset in inches as float by converting fixed-point microns via png_get_x_offset_microns and multiplying by scale factor DAT_011bd4a0. |
| 0x00E7BC40 | 26 | png_get_x_offset_inches_fixed | libpng: png_get_x_offset_inches_fixed - returns x offset in inches as fixed-point by calling png_get_x_offset_microns and converting via FUN_00e7ac90. |
| 0x00E7BC60 | 46 | png_get_x_offset_microns | libpng: png_get_x_offset_microns - returns x offset in microns from tRNS data if unit_type==1 (microns). Checks flag bit 0x100, reads offset 0xb4. Returns 0 if not micron type. |
| 0x00E7BC90 | 46 | png_get_x_offset_pixels | libpng: png_get_x_offset_pixels - returns x offset in pixels if unit_type==0 (pixels). Checks flag bit 0x100, reads offset 0xb4. Returns 0 if not pixel type. |
| 0x00E7BCC0 | 25 | png_get_x_pixels_per_inch | libpng: png_get_x_pixels_per_inch - returns x DPI by calling png_get_x_ppu_meter and converting via FUN_00e7be20 (meters to inches). |
| 0x00E7BCE0 | 43 | png_get_x_pixels_per_meter | libpng: png_get_x_pixels_per_meter - returns x pixels per unit when unit_type==1 (meters). Reads pHYs x_ppu at offset 0xc0. Was misnamed png_get_x_ppu_meter. |
| 0x00E7BD10 | 50 | png_get_y_offset_inches | libpng: png_get_y_offset_inches - returns y offset in inches as float by converting fixed-point microns via png_get_y_offset_microns and multiplying by scale factor. |
| 0x00E7BD50 | 26 | png_get_y_offset_inches_fixed | libpng: png_get_y_offset_inches_fixed - returns y offset in inches as fixed-point by calling png_get_y_offset_microns and converting. |
| 0x00E7BD70 | 46 | png_get_y_offset_microns | libpng: png_get_y_offset_microns - returns y offset in microns from tRNS data if unit_type==1. Checks flag bit 0x100, reads offset 0xb8. Returns 0 if not micron type. |
| 0x00E7BDA0 | 46 | png_get_y_offset_pixels | libpng: png_get_y_offset_pixels - returns y offset in pixels if unit_type==0 (pixels). Checks flag bit 0x100, reads offset 0xb8. Returns 0 if not pixel type. |
| 0x00E7BDD0 | 25 | png_get_y_pixels_per_inch | libpng: png_get_y_pixels_per_inch - returns y DPI by calling png_get_y_ppu_meter and converting to inches. |
| 0x00E7BDF0 | 43 | png_get_y_pixels_per_meter | libpng: png_get_y_pixels_per_meter - returns y pixels per unit when unit_type==1 (meters). Reads pHYs y_ppu at offset 0xc4. Was misnamed png_get_y_ppu_meter. |
| 0x00E7BE20 | 46 | png_ppi_from_ppm | libpng: png_ppi_from_ppm - converts pixels per meter to pixels per inch using fixed-point multiplication (ppm * 127 / 5000). Returns 0 on overflow or failure. |
| 0x00E7BE60 | 75 | png_image_write_to_memory_append | libpng: png_image_write_to_memory_append - appends data to an in-memory write buffer. Checks for overflow, copies data via memcpy. Aborts via png error on buffer overflow. |
| 0x00E7BEB0 | 59 | png_convert_from_struct_tm | libpng: png_convert_from_struct_tm - converts a C struct tm to png_time format. Maps year (+1900), month (+1), day, hour, minute, second fields. |
| 0x00E7BEF0 | 26 | png_convert_from_time_t | libpng: png_convert_from_time_t - converts time_t to png_time by calling _gmtime64 then png_convert_from_struct_tm. |
| 0x00E7BF10 | 31 | png_create_read_struct | libpng: png_create_read_struct - simplified wrapper that calls png_create_read_struct_2 with NULL mem alloc/free functions. |
| 0x00E7BF30 | 180 | png_create_read_struct_2 | libpng: png_create_read_struct_2 - creates and initializes a png_structp for reading. Sets mode flags, default buffer size 0x2000, zlib compression params (level=-1, method=8, window=15, mem=8, strategy=0). Calls png__create_read_struct and FUN_00e87520. |
| 0x00E7BFF0 | 52 | png_destroy_read_struct | libpng: png_destroy_read_struct - destroys a read png_struct. Frees info struct, cleans up internal state via FUN_00e7d130, and frees memory via FUN_00e7e090. |
| 0x00E7C030 | 210 | png_image_write_filter_sub | libpng: png_image_write_filter_sub - applies sub-filter to PNG image row data during writing. Handles both 8-bit and 16-bit color types (RGB and RGBA). Subtracts previous pixel channel values for filtering. |
| 0x00E7C110 | 996 | png_image_write_colormap | libpng: png_image_write_colormap - converts a color-mapped image palette to PNG PLTE and optional tRNS chunks. Handles 16-bit to 8-bit conversion with gamma correction via lookup tables. Processes alpha channel for transparency. |
| 0x00E7C5B0 | 158 | png_image_write_init | libpng: png_image_write_init - initializes PNG write structures. Creates read struct, info struct, allocates control block (6 ints), sets up error/warning handlers. Returns 1 on success, error message on failure. |
| 0x00E7C650 | 909 | png_image_write_main | libpng: png_image_write_main - core PNG write implementation. Sets up IHDR with proper color type/bit depth, applies sRGB/gamma/chromaticity settings, handles color-mapped images, writes rows, and finalizes with png_write_end. Manages interlacing, alpha, and color swapping transforms. |
| 0x00E7C9E0 | 41 | png_image_write_to_memory_callback | libpng: png_image_write_to_memory_callback - callback for writing PNG to memory. Sets up custom write function (png_image_write_to_memory_append) then delegates to png_image_write_main. |
| 0x00E7CA10 | 293 | png_image_write_to_file | libpng: png_image_write_to_file - writes a PNG image to a file. Opens file with fopen, calls png_image_write_to_stdio, handles errors (fflush/ferror/fclose). Removes file on failure. |
| 0x00E7CB40 | 242 | png_image_write_to_memory | libpng: png_image_write_to_memory - writes PNG to a memory buffer. Validates params, initializes write structures, calls write callback. Sets output size in param_3. Returns 0 if buffer too small. |
| 0x00E7CC40 | 192 | png_image_write_to_stdio | libpng: png_image_write_to_stdio - writes PNG image to a FILE* stream. Validates params, initializes write structures, sets file pointer, calls png_image_write_main. Frees image on completion. |
| 0x00E7CD00 | 21 | png_set_compression_level | libpng: png_set_compression_level - sets the zlib compression level in png_struct at offset 0xc4. No-op if png_ptr is NULL. |
| 0x00E7CD20 | 21 | png_set_compression_mem_level | libpng: png_set_compression_mem_level - sets zlib memory level in png_struct at offset 0xd0. |
| 0x00E7CD40 | 44 | png_set_compression_method | libpng: png_set_compression_method - sets compression method in png_struct at offset 0xc8. Warns if method != 8 (deflate). Only method 8 is supported. |
| 0x00E7CD70 | 25 | png_set_compression_strategy | libpng: png_set_compression_strategy - sets zlib compression strategy in png_struct at offset 0xd4. Also sets flag bit 0x1 in mode field at 0x78. |
| 0x00E7CD90 | 80 | png_set_compression_window_bits | libpng: png_set_compression_window_bits - sets zlib window bits in png_struct at offset 0xcc. Clamps to range [8, 15] with warnings. |
| 0x00E7CDE0 | 355 | png_set_filter | libpng: png_set_filter - sets PNG row filter method and filter selection flags. Validates filter method (0 or 0x40). Allocates filter buffers if needed. Supports SUB(0x10), UP(0x20), AVG(0x40), PAETH(0x80), NONE(0x08) filters. |
| 0x00E7CF90 | 28 | png_set_flush | libpng: png_set_flush - sets the number of rows between flushes in png_struct at offset 0x180. Clamps negative values to 0. |
| 0x00E7CFB0 | 21 | png_set_text_compression_level | libpng: png_set_text_compression_level - sets text compression level in png_struct at offset 0xd8. |
| 0x00E7CFD0 | 21 | png_set_text_compression_mem_level | libpng: png_set_text_compression_mem_level - sets text compression memory level in png_struct at offset 0xe4. |
| 0x00E7CFF0 | 44 | png_set_text_compression_method | libpng: png_set_text_compression_method - sets text compression method in png_struct at offset 0xdc. Warns if not 8 (deflate). |
| 0x00E7D020 | 21 | png_set_text_compression_strategy | libpng: png_set_text_compression_strategy - sets text compression strategy in png_struct at offset 0xe8. |
| 0x00E7D040 | 80 | png_set_text_compression_window_bits | libpng: png_set_text_compression_window_bits - sets text compression window bits in png_struct at offset 0xe0. Clamps to range [8, 15]. |
| 0x00E7D090 | 21 | png_set_write_user_transform_fn | libpng: png_set_write_user_transform_fn - sets user write transform callback in png_struct at offset 0x1c8. |
| 0x00E7D0B0 | 25 | png_set_write_fn_00e7d0b0 | libpng: png_set_write_fn - sets custom write function pointer in png_struct at offset 0x68. Sets flag bit 0x100000 in mode at 0x7c to indicate write mode. |
| 0x00E7D0D0 | 96 | png_gamma_correct_16_to_8 | libpng: png_gamma_correct_16_to_8 - converts a 16-bit color value to 8-bit with gamma correction. Uses pre-multiplied alpha (param_3) and gamma lookup table at DAT_011bb5b8/DAT_011bb1b8. Returns 0xff if value >= max. |
| 0x00E7D130 | 157 | png_write_destroy | libpng: png_write_destroy - cleans up internal write state. Frees zlib stream, row buffers (0x124, 0x120, 0x12c, 0x130), previous row (0x248). Resets pointers to 0. |
| 0x00E7D1D0 | 355 | png_write_end | libpng: png_write_end - finishes writing a PNG file. Verifies IDATs were written, checks palette index bounds. Writes trailing chunks (bKGD, text, eXIf, unknown chunks). Writes IEND chunk and flushes output. |
| 0x00E7D340 | 59 | png_write_flush_rows | libpng: png_write_flush_rows - flushes buffered row data to output. Calls FUN_00e7e400 with sync flush (mode=2), resets row counter at 0x184, and calls png_write_flush. |
| 0x00E7D380 | 89 | png_write_image | libpng: png_write_image - writes all rows of a PNG image. Iterates through interlace passes (via png_set_interlace_handling), writing each row via png_write_row. |
| 0x00E7D3E0 | 338 | png_image_write_rows_16bit | libpng: png_image_write_rows_16bit - writes 16-bit per channel image rows. Handles alpha pre-multiplication for RGBA/GA. Processes rows by converting alpha-premultiplied data and writing via png_write_row. Called from png_image_write_main for linear (16-bit) format. |
| 0x00E7D540 | 455 | png_image_write_rows_sRGB | libpng: png_image_write_rows_sRGB - writes sRGB (8-bit) image rows with gamma correction. Handles alpha pre-multiplication and 16-to-8 bit conversion via gamma lookup tables. Processes RGBA/GA and RGB/Gray separately. |
| 0x00E7D710 | 847 | png_write_info_before_PLTE | libpng: png_write_info_before_PLTE - writes all PNG info chunks that come before PLTE. Handles IHDR, oFFs, palette (with optional inversion), sCAL, eXIf, pHYs, tRNS, sPLT, sCAL, tIME, bKGD, unknown chunks, and text. Also calls png_write_info for remaining chunks. |
| 0x00E7DA60 | 326 | png_write_info | libpng: png_write_info - writes PNG header info chunks (IHDR, sRGB/iCCP, gAMA, cHRM, sBIT). Checks for MNG features and writes sigBit, cHRM data. Delegates to png_write_info_before_PLTE for pre-PLTE chunks. Sets 0x400 flag when done. |
| 0x00E7DBB0 | 290 | png_write_png | libpng: png_write_png - high-level function that writes a complete PNG file. Applies requested transforms (interlace, packing, shift, BGR, swap_alpha, filler_strip, invert_alpha, swap, invert), then calls png_write_image + png_write_end. |
| 0x00E7DCE0 | 635 | png_write_row | libpng: png_write_row - writes a single row of PNG data. Handles interlacing (Adam7), applies write transforms, sub-filtering for MNG, palette index tracking. Copies row data, applies filters, and compresses via FUN_00e7ff60. |
| 0x00E7DF80 | 47 | png_write_rows | libpng: png_write_rows - writes multiple rows of PNG data by iterating and calling png_write_row for each row pointer in the array. |
| 0x00E7DFB0 | 163 | png_write_unknown_chunks | libpng: png_write_unknown_chunks - iterates over unknown chunks in png_info and writes them. Checks chunk filter flags and safe-to-copy bit. Warns if writing zero-length chunks. |
| 0x00E7E060 | 43 | png_calloc | libpng: png_calloc - allocates and zero-initializes memory. Calls png_malloc then memset to zero. Returns NULL on allocation failure. |
| 0x00E7E090 | 102 | png_destroy_struct | libpng: png_destroy_struct - safely destroys a png_struct. Copies struct to stack, zeros original, then frees it. This prevents use-after-free by clearing before calling the free function. |
| 0x00E7E100 | 50 | png_free | libpng: png_free - frees memory allocated by png. If a custom free function is set at png_struct+0x264, calls it; otherwise calls png_free_default (which uses C free). |
| 0x00E7E140 | 27 | png_free_default | libpng: png_free_default - default memory free function. Calls C free() if both png_ptr and ptr are non-NULL. |
| 0x00E7E160 | 20 | png_get_mem_ptr | libpng: png_get_mem_ptr - returns the memory allocation context pointer from png_struct at offset 0x25c. Returns 0 if png_ptr is NULL. |
| 0x00E7E180 | 43 | png_malloc | libpng: png_malloc - allocates memory. Calls png_malloc_warn and aborts with png_error("Out of memory") on failure. |
| 0x00E7E1B0 | 42 | png_malloc_array | libpng: png_malloc_array - allocates an array. Validates count > 0 and element_size != 0, then delegates to png_malloc_array_checked. Aborts on invalid params. |
| 0x00E7E1E0 | 40 | png_malloc_array_checked | libpng: png_malloc_array_checked - allocates count * element_size bytes with overflow check. Returns NULL on overflow or allocation failure. |
| 0x00E7E210 | 51 | png_malloc_warn | libpng: png_malloc_warn - allocates memory. If custom allocator is set at png_struct+0x260, uses it; otherwise falls back to C malloc. Returns NULL on failure instead of aborting. |
| 0x00E7E250 | 43 | png_malloc_base | libpng: png_malloc_base - allocates memory with a slightly different error message ("Out of Memory" with capital M). Calls png_malloc_warn(NULL, size), aborts on failure. |
| 0x00E7E280 | 46 | png_malloc_warn_with_warning | libpng: png_malloc_warn_with_warning - allocates memory via png_malloc_warn but issues a warning instead of aborting on failure. Returns 0 on failure. |
| 0x00E7E2B0 | 144 | png_realloc_array | libpng: png_realloc_array - reallocates an array with new additional elements. Copies old_count * element_size bytes, zeros new elements. Validates params and checks for overflow. Returns NULL on failure. |
| 0x00E7E350 | 39 | png_set_mem_fn | libpng: png_set_mem_fn - sets custom memory allocation/free functions and context pointer in png_struct at offsets 0x25c (mem_ptr), 0x260 (malloc_fn), 0x264 (free_fn). |
| 0x00E7E380 | 119 | png_zlib_window_adjust | libpng: png_zlib_window_adjust - adjusts the zlib window size in the header bytes to match the actual data size. Reduces window size if data is smaller than current window, then fixes the checksum modulo 31. |
| 0x00E7E400 | 525 | png_compress_IDAT | libpng: png_compress_IDAT - compresses and writes IDAT chunk data. Manages zlib deflate stream, allocates output buffer on first call. Writes IDAT chunks when buffer is full. Handles flush modes and adjusts zlib window size on first chunk. |
| 0x00E7E610 | 585 | png_zlib_deflate_init | libpng: png_zlib_deflate_init - initializes or resets the zlib deflate stream for a given chunk type. Configures compression params from png_struct (level, method, window, mem_level, strategy). For non-IDAT, uses text compression settings. Adjusts window size for small data. |
| 0x00E7E860 | 565 | png_do_write_interlace | libpng: png_do_write_interlace - extracts pixels for the current Adam7 interlace pass. Handles 1, 2, 4 bit depths (packing into bytes) and 8+ bit depths (memcpy). Updates row width and rowbytes for the extracted pass. |
| 0x00E7EAA0 | 45 | png_free_buffer_list | libpng: png_free_buffer_list - frees a linked list of buffers. Walks the list following next pointers and calls png_free on each node. Sets the head pointer to NULL. |
| 0x00E7EAD0 | 339 | png_estimate_image_data_size | libpng: png_estimate_image_data_size - estimates uncompressed IDAT data size for zlib window optimization. Handles interlaced images by calculating per-pass sizes. Returns -1 if dimensions exceed 0x8000. |
| 0x00E7EC30 | 21 | png_save_uint_16 | libpng: png_save_uint_16 - writes a 16-bit value in big-endian byte order to a buffer. |
| 0x00E7EC50 | 37 | png_save_uint_32 | libpng: png_save_uint_32 - writes a 32-bit value in big-endian byte order to a buffer. |
| 0x00E7EC80 | 219 | png_write_filter_avg | libpng: png_write_filter_avg - applies the Average filter (type 3) to a row. For first bpp bytes, averages with previous row only. For remaining bytes, averages current with left and above. Returns sum of absolute differences for filter selection. |
| 0x00E7ED60 | 505 | png_write_filter_avg_sse | libpng: png_write_filter_avg_sse - SSE-optimized version of the Average filter (type 3). Processes 8 bytes at a time using SSE instructions (pshuflw, pshufhw). Falls back to scalar for remaining bytes. |
| 0x00E7EF60 | 293 | png_write_filter_paeth | libpng: png_write_filter_paeth - applies the Paeth filter (type 4) to a row. Predicts each byte using the Paeth predictor (left, above, upper-left). Returns sum of absolute differences for filter selection. Exits early if sum exceeds threshold. |
| 0x00E7F090 | 358 | png_write_filter_paeth_optimized | libpng: png_write_filter_paeth_optimized - unrolled/optimized version of Paeth filter application. Processes 64 bytes at a time for the initial bpp portion, then uses scalar Paeth prediction for remaining bytes. |
| 0x00E7F200 | 151 | png_write_filter_sub | libpng: png_write_filter_sub - applies Sub filter (type 1) to a row and returns sum of absolute differences. First bpp bytes are copied as-is; remaining bytes subtract left neighbor. Returns early if sum exceeds threshold. |
| 0x00E7F2A0 | 279 | png_write_filter_sub_optimized | libpng: png_write_filter_sub_optimized - unrolled/optimized version of Sub filter application. Processes 64 bytes at a time for initial bpp, then scalar for remaining. Does not compute sum (void return). |
| 0x00E7F3C0 | 105 | png_write_filter_up | libpng: png_write_filter_up - applies Up filter (type 2) and returns sum of absolute differences. Each byte is subtracted from the byte directly above it in the previous row. Returns early if sum exceeds threshold. |
| 0x00E7F430 | 215 | png_write_filter_up_optimized | libpng: png_write_filter_up_optimized - unrolled/optimized version of Up filter. Processes 64 bytes at a time. Does not compute sum (void return). |
| 0x00E7F510 | 389 | png_text_compress | libpng: png_text_compress - compresses text data using zlib deflate. Manages buffer linked list for output. Initializes deflate stream, feeds data, handles buffer overflow by allocating more buffers. Used for tEXt/zTXt/iTXt chunks. |
| 0x00E7F6A0 | 26 | png_text_compress_init | libpng: png_text_compress_init - initializes a text compression structure with input data pointer and length. Resets output size to 0. |
| 0x00E7F6C0 | 32 | png_write_IEND | libpng: png_write_IEND - writes the IEND chunk (0x49454e44) with 0 data bytes. Sets flag 0x10 in mode to mark end of image. |
| 0x00E7F6E0 | 645 | png_write_IHDR | libpng: png_write_IHDR - writes the IHDR chunk. Validates width, height, bit_depth, color_type, compression, filter, interlace params. Sets internal struct fields (channels, pixel_depth, rowbytes). Writes 13-byte IHDR data. Sets default filter mask. |
| 0x00E7F9B0 | 194 | png_write_PLTE | libpng: png_write_PLTE - writes the PLTE chunk. Validates palette size (max 2^bit_depth, max 256). Writes 3 bytes per entry (R,G,B). Sets flag 0x2 in mode. Warns for non-palette color types. |
| 0x00E7FA80 | 338 | png_write_bKGD | libpng: png_write_bKGD - writes the bKGD (background color) chunk. Handles palette index (1 byte), grayscale (2 bytes), and RGB (6 bytes) background formats. Validates values against bit depth. |
| 0x00E7FBE0 | 158 | png_write_cHRM_fixed | libpng: png_write_cHRM_fixed - writes the cHRM chunk with 8 fixed-point chromaticity values (white_x/y, red_x/y, green_x/y, blue_x/y) as big-endian 32-bit integers. 32 bytes total. |
| 0x00E7FC80 | 45 | png_write_complete_chunk | libpng: png_write_complete_chunk - wrapper that writes a complete PNG chunk (header + data + CRC) by calling png_write_chunk_internal. |
| 0x00E7FCB0 | 51 | png_write_chunk_data | libpng: png_write_chunk_data - writes chunk data bytes and updates the running CRC. Validates all pointers and length are non-null/non-zero. |
| 0x00E7FCF0 | 54 | png_write_chunk_end | libpng: png_write_chunk_end - finalizes a PNG chunk by writing the 4-byte CRC. Sets state to 0x82 and writes CRC from png_struct+0x13c as big-endian. |
| 0x00E7FD30 | 125 | png_write_chunk_header | libpng: png_write_chunk_header - writes chunk header (4-byte length + 4-byte type). Sets state to 0x22, resets CRC, updates CRC with chunk type. Stores chunk type at png_struct+0x11c. Sets state to 0x42. |
| 0x00E7FDB0 | 45 | png_write_chunk_start | libpng: png_write_chunk_start - wrapper for png_write_chunk_header. Begins writing a new chunk. |
| 0x00E7FDE0 | 67 | png_write_chunk | libpng: png_write_chunk - writes a complete PNG chunk (header + data + CRC). Validates length < 0x7FFFFFFF. Calls png_write_chunk_header, png_write_chunk_data, png_write_chunk_end. |
| 0x00E7FE30 | 96 | png_write_compressed_data | libpng: png_write_compressed_data - writes compressed chunk data from a linked buffer list. Iterates through buffers writing 0x400-byte blocks, then remaining data from overflow buffers. Aborts if data remains after all buffers consumed. |
| 0x00E7FEA0 | 76 | png_write_eXIf | libpng: png_write_eXIf - writes the eXIf chunk (0x65584966). Writes chunk header, then each byte individually via png_write_chunk_data, then the CRC trailer. |
| 0x00E7FEF0 | 100 | png__write_row | Writes a single row of PNG image data. Compresses the row via png_compress_IDAT, swaps row buffers if needed, finishes the row, increments row counter, and flushes if the flush interval has been reached. |
| 0x00E7FF60 | 540 | png_write_find_filter | libpng: png_write_find_filter - selects the best PNG row filter by comparing None, Sub, Up, Average, and Paeth filters. Computes sum of absolute differences for each enabled filter and picks the one with the lowest sum. Uses optimized versions when only one filter is selected. |
| 0x00E80180 | 315 | png_write_finish_row | libpng: png_write_finish_row - completes writing a row. Increments row counter, advances interlace pass if needed (Adam7). Calculates new pass dimensions. When all passes complete, finalizes IDAT compression with Z_FINISH. |
| 0x00E802C0 | 42 | png_write_gAMA_fixed | libpng: png_write_gAMA_fixed - writes the gAMA chunk with a fixed-point gamma value as a 4-byte big-endian integer. |
| 0x00E802F0 | 116 | png_write_hIST | libpng: png_write_hIST - writes the hIST chunk with histogram data. Validates entry count against palette size. Writes each 16-bit frequency value in big-endian order. |
| 0x00E80370 | 305 | png_write_iCCP | libpng: png_write_iCCP - writes the iCCP chunk with an ICC color profile. Validates profile length (min 0x84) and version. Compresses profile data using zlib. Writes keyword + null + compression_method + compressed_profile. |
| 0x00E804B0 | 601 | png__write_iTXt | Writes a PNG iTXt (international text) chunk. Validates keyword via FUN_00e81310, handles compression modes (0/2=compressed, -1/1=uncompressed), writes keyword, language tag, translated keyword, and text content. For compressed mode, uses zlib deflate via png_text_compress. Outputs chunk header, data segments, and chunk end. |
| 0x00E80720 | 106 | png_write_oFFs | libpng: png_write_oFFs - writes the oFFs chunk with image offset data (x_offset, y_offset as signed 32-bit big-endian + unit_type byte). Warns if unit_type > 1. |
| 0x00E80790 | 408 | png__write_pCAL | Writes a PNG pCAL (calibration of pixel values) chunk. Validates equation type (0-3) and keyword, computes total chunk size from keyword, units string, and parameter strings. Writes chunk header, keyword, min/max as big-endian int32, equation type, parameter count, units, and parameter values. |
| 0x00E80930 | 106 | png__write_pHYs | Writes a PNG pHYs (physical pixel dimensions) chunk. Stores X and Y pixels-per-unit as big-endian uint32, plus unit type byte. Warns if unit type > 1. |
| 0x00E809A0 | 204 | png__write_sBIT | Writes a PNG sBIT (significant bits) chunk. For grayscale (param_3 & 2 == 0): writes 1 byte. For RGB (param_3 & 2): writes 3 bytes (R, G, B). If alpha (param_3 & 4): appends alpha significant bits. Validates all bit depths are > 0 and <= image bit depth. |
| 0x00E80A70 | 189 | png__write_sCAL | Writes a PNG sCAL (physical scale of image subject) chunk. Writes unit type byte, followed by width string and height string separated by null. Warns if combined data exceeds 0x40 bytes buffer. |
| 0x00E80B30 | 337 | png__write_sPLT | Writes a PNG sPLT (suggested palette) chunk. Validates keyword, writes chunk header with computed size. For 8-bit palettes: writes 6 bytes per entry (RGBA + freq). For 16-bit: writes 10 bytes per entry (RGBA as uint16 + freq as uint16). Each entry has R, G, B, A components and a frequency value. |
| 0x00E80C90 | 56 | png_write_sRGB | libpng: png_write_sRGB - writes the sRGB chunk with rendering intent (1 byte). Warns if intent > 3. |
| 0x00E80CD0 | 105 | png_write_sig | libpng: png_write_sig - writes the 8-byte PNG file signature (89 50 4E 47 0D 0A 1A 0A). Accounts for already-written signature bytes. Sets PNG mode flag 0x1000 if less than 3 bytes were skipped. |
| 0x00E80D40 | 326 | png__write_start_row | Initializes PNG row writing state. Computes row bytes from bit depth and channels, allocates row buffer, sets up filter buffers based on filter mode flags, allocates previous row buffer for multi-row filters. Adjusts dimensions for interlaced images if interlace handling is not enabled. |
| 0x00E80E90 | 187 | png__write_tEXt | Writes a PNG tEXt (uncompressed text) chunk. Validates keyword, computes text length, checks total size doesn't overflow. Writes chunk header, keyword + null terminator, then text data. Errors on invalid keyword or text too long. |
| 0x00E80F50 | 164 | png_write_tIME | libpng: png_write_tIME - writes the tIME chunk with last modification time (7 bytes: year, month, day, hour, minute, second). Validates ranges before writing. |
| 0x00E81000 | 319 | png__write_tRNS | Writes a PNG tRNS (transparency) chunk. For palette images (type 3): writes palette transparency entries. For grayscale (type 0): writes 2-byte gray value. For RGB (type 2): writes 6 bytes (R, G, B as uint16). Validates values against bit depth and palette size. Errors for images with alpha channel. |
| 0x00E81140 | 287 | png__write_zTXt | Writes a PNG zTXt (compressed text) chunk. For compression type -1, delegates to png__write_tEXt. For type 0 (zlib deflate): validates keyword, compresses text, writes keyword + compression byte + compressed data. Errors on invalid compression type or keyword. |
| 0x00E81260 | 67 | png__check_chunk_name_entry | Searches a list of 5-byte chunk name entries for a matching 4-byte name. If found, updates the flags byte. If not found and param_4 is non-zero, appends a new entry. Returns updated count. |
| 0x00E812B0 | 93 | png__check_location | Validates and normalizes a chunk location mask. Masks to valid bits (0xB), validates against current state, and extracts lowest set bit if multiple location flags are set. Errors if no valid location. |
| 0x00E81310 | 306 | png__check_keyword | Validates and sanitizes a PNG text keyword. Copies valid characters (0x21-0x7E, 0xA1+) to output, collapses multiple spaces, strips leading/trailing whitespace. Truncates at 79 chars with warning. Warns about bad characters. Returns keyword length, 0 on failure. |
| 0x00E81450 | 28 | png__set_rgb_to_gray_mode | Sets the RGB-to-gray conversion error action mode. Masks param_2 to valid bits (0x5) and stores at offset 0x254. Returns the stored value. Returns 0 if PNG struct is null. |
| 0x00E81470 | 192 | png__set_IHDR | Sets PNG IHDR (image header) parameters in the info struct. Stores width, height, bit depth, color type, interlace, compression, filter method. Validates via png__validate_IHDR. Computes channels (1 for grayscale/palette, 3 for RGB) + alpha, pixel depth, and row bytes. |
| 0x00E81530 | 227 | png__set_PLTE_impl | libpng: Sets PLTE (palette) data in info/png struct. Validates palette size against color type limits (2^bit_depth for palette type, 256 max). Allocates 768-byte (256*3) palette buffer, copies entries, sets palette count at offsets 0x10/0x14 and 0x140/0x144. |
| 0x00E81620 | 52 | png__set_gAMA_fixed | Libpng png_set_gAMA_fixed: sets the gamma value in the PNG info structure using fixed-point representation. |
| 0x00E81660 | 34 | png__set_invalid_chunk_handler | Libpng png_set_invalid_chunk_handler: sets the callback for handling invalid or unknown PNG chunks. |
| 0x00E81690 | 246 | png__set_cHRM_double | libpng: Sets cHRM (primary chromaticities and white point) from double-precision xy coordinates. Converts 8 doubles (white X/Y, red X/Y, green X/Y, blue X/Y) to fixed-point via png__float_to_fixed_point, then delegates to png__set_cHRM_fixed_impl. |
| 0x00E81790 | 274 | png__set_cHRM_XYZ_double | libpng: Sets cHRM from double-precision XYZ (tristimulus) coordinates. Converts 9 doubles (red/green/blue X/Y/Z) to fixed-point, then delegates to png__set_cHRM_XYZ_fixed. |
| 0x00E818B0 | 140 | png__set_cHRM_XYZ_fixed | libpng: Sets cHRM from fixed-point XYZ (tristimulus) endpoints. Calls png__colorspace_set_endpoints with the 9 fixed-point values and sets chromaticity valid flag 0x10 on info struct. |
| 0x00E81940 | 134 | png__set_cHRM_fixed_impl | libpng: Sets cHRM from fixed-point xy chromaticity coordinates. Calls png__colorspace_set_chromaticities_from_xy with 8 fixed-point values (white/red/green/blue x/y) and sets chromaticity valid flag 0x10. |
| 0x00E819D0 | 23 | png__permit_mng_features_impl | libpng: png_permit_mng_features. Sets MNG features permitted flag at offset 0x148. If param_2 > 0, enables (sets 0), otherwise disables (sets -1/0xFFFFFFFF). |
| 0x00E819F0 | 21 | png__set_num_palette_entries | PNG library setter. Sets num_palette field (offset 0x284) on png_info struct. Null-checks the struct pointer. |
| 0x00E81A10 | 21 | png__set_num_trans | PNG library setter. Sets num_trans field (offset 0x288) on png_info struct. Null-checks the struct pointer before writing. |
| 0x00E81A30 | 141 | png__set_compression_buffer_size | libpng: Sets the compression buffer size. For write structs (flag 0x8000), sets at offset 0x2AC. For read structs, validates minimum of 6 bytes, frees existing buffer list, and stores new size at offset 0xC0. Errors on 0 or >0x7FFFFFFF. |
| 0x00E81AC0 | 21 | png__warn_set_eXIf_deprecated | PNG library function. Emits warning that png_set_eXIf is deprecated, should use png_set_eXIf_1 instead. Wrapper around png__warning with a static message. |
| 0x00E81AE0 | 155 | png__set_eXIf_data | libpng: Sets eXIf (Exif metadata) chunk data. Allocates buffer and copies raw Exif data. Stores length at offset 0xCC, data pointer at 0xD0. Sets free flag 0x8000 and valid flag 0x10000. |
| 0x00E81B80 | 46 | png__set_gAMA_double | libpng: Sets gAMA (gamma) from a double-precision value. Converts to fixed-point via png__float_to_fixed_point (with "png_set_gAMA" context string), then delegates to png__set_gAMA_fixed_impl. |
| 0x00E81BB0 | 46 | png__set_gAMA_fixed_impl | libpng: Sets gAMA (gamma) from a fixed-point value. Calls png__colorspace_set_gamma on the info struct's colorspace, then updates colorspace flags. |
| 0x00E81BE0 | 168 | png__set_hIST | Libpng png_set_hIST: sets the histogram data for palette-based PNG images in the info structure. |
| 0x00E81C90 | 302 | png__set_iCCP_impl | libpng: Sets iCCP (embedded ICC color profile) chunk data. Validates compression method, sets chromaticities from profile, stores profile name and compressed data at offsets 0x74-0x7C. Sets info flags 0x10 (free mask) and 0x1000 (valid). |
| 0x00E81DC0 | 26 | png__clear_info_flag_bits | PNG library function. Clears specific flag bits in a png_info struct's flags field (offset 8). Takes png_ptr, info_ptr, and bitmask. AND-NOTs the mask against the flags. |
| 0x00E81DE0 | 407 | png__set_keep_unknown_chunks_impl | libpng: Internal implementation of png_set_keep_unknown_chunks. Manages the list of chunk names with keep/discard disposition at offsets 0x240 (default), 0x244 (count), 0x248 (list). Handles add, remove, and compact operations. |
| 0x00E81F80 | 52 | png__set_sCAL_s | Libpng png_set_sCAL_s: sets the physical scale (sCAL chunk) for the PNG image using string representations. |
| 0x00E81FC0 | 616 | png__set_pCAL | libpng: Sets pCAL (calibration of pixel values) chunk data in info struct. Validates equation type (0-3), parameter count (0-255), and numeric string format. Stores purpose string, X0/X1 ranges, equation type, parameter count, units string, and parameter strings at offsets 0xDC-0xF4. |
| 0x00E82230 | 52 | png__set_oFFs | libpng: Sets oFFs (image offset) chunk data. Stores X offset at 0xC0, Y offset at 0xC4, and unit type at 0xC8 on info struct. Sets PNG_INFO_oFFs flag (0x80). |
| 0x00E82270 | 30 | png__set_image_dimensions | PNG library function. Sets image width (offset 0x238) and height (offset 0x23c) on a PNG struct. Null-checks the struct pointer first. |
| 0x00E82290 | 71 | png__set_rows | libpng: Sets row pointers in info struct. Stores pointer at offset 0x114, frees old data if different. Sets PNG_INFO flag 0x8000 when data is present. |
| 0x00E822E0 | 46 | png_set_sCAL_s_params | libpng: Sets sCAL chunk parameters (unit and dimensions) on png_info struct. Sets flag bit 0x2 in valid flags. |
| 0x00E82310 | 194 | png_set_sCAL_float | libpng: png_set_sCAL with float width/height. Converts doubles to strings then calls png_set_sCAL_string. |
| 0x00E823E0 | 162 | png_set_sCAL_fixed | libpng: png_set_sCAL with fixed-point integer width/height. Converts to strings then calls png_set_sCAL_string. |
| 0x00E82490 | 370 | png_set_sCAL_string | libpng: Sets sCAL chunk from string width/height. Validates unit (1=meter, 2=radian), checks non-negative values, allocates and copies strings to info struct. |
| 0x00E82610 | 367 | png_set_sPLT | libpng: Sets sPLT (suggested palette) entries. Grows array, copies name/entries/depth for each sPLT entry. Sets valid flag 0x2000. |
| 0x00E82780 | 46 | png_set_sRGB | libpng: Sets sRGB rendering intent on png_info. Calls colorspace check and update functions. |
| 0x00E827B0 | 58 | png_set_sRGB_gAMA_and_cHRM | libpng: Sets sRGB intent and also updates gAMA and cHRM chunks. Sets flag bits 0x18 on info if colorspace check succeeds. |
| 0x00E827F0 | 120 | png_set_tIME | libpng: Sets tIME (last modification time) chunk. Validates month (1-12), day (1-31), hour (0-23), minute (0-59), second (0-60). Sets valid flag 0x200. |
| 0x00E82870 | 260 | png_set_tRNS | libpng: Sets tRNS (transparency) chunk. Handles palette transparency (alpha bytes), grayscale trans color, and RGB trans color. Validates sample range against bit depth. Sets valid flag 0x10. |
| 0x00E82980 | 42 | png_set_text | libpng: Public png_set_text wrapper. Calls png_set_text_internal and errors on OOM. |
| 0x00E829B0 | 768 | png_set_text_internal | libpng: Internal text chunk setter. Grows text array, copies key/lang/lang_key/text for each text entry. Handles compressed and uncompressed text. Sets valid flag on info. |
| 0x00E82CB0 | 104 | png_set_unknown_chunk_location | libpng: Sets the location of an unknown chunk by index. Validates chunk index and location flags. |
| 0x00E82D20 | 284 | png_set_unknown_chunks | libpng: Sets unknown chunk entries. Grows array, copies name/data/size/location for each chunk. Sets valid flag 0x200. |
| 0x00E82E40 | 30 | png_set_read_user_chunk_fn | libpng: Sets the user chunk read callback function and data pointer on the png_struct. |
| 0x00E82E60 | 237 | png_handle_unknown_chunk | libpng: Handles reading of an unknown PNG chunk. Stores chunk name, allocates buffer for data, reads data, and finishes CRC. Manages memory limits. |
| 0x00E82F50 | 184 | png_check_chunk_length | libpng: Validates chunk data length. For IDAT chunks, calculates expected max size from image dimensions and compression overhead. Errors if chunk exceeds memory limit. |
| 0x00E83010 | 62 | png_check_chunk_name | libpng: Validates a 4-byte chunk type name. Each byte must be ASCII letter (A-Z or a-z). Errors on invalid chunk type. |
| 0x00E83050 | 1138 | png_combine_row | libpng: Combines a decoded row with the existing image row for interlaced images. Handles sub-byte pixel depths (1/2/4 bit) with masking, and byte-aligned depths with optimized copy loops. Preserves partial bytes at row end. |
| 0x00E834D0 | 140 | png_read_chunk_crc | libpng: Reads and checks CRC for current chunk. Reads 4 bytes, byte-swaps to big-endian, compares with accumulated CRC. Returns true if CRC mismatch. |
| 0x00E83560 | 168 | png_crc_finish | libpng: Finishes reading a chunk by consuming remaining data and checking CRC. Reads data in 1024-byte blocks, then verifies CRC. Errors or warns on CRC mismatch. |
| 0x00E83610 | 41 | png_crc_read | libpng: Reads data from PNG stream and updates CRC. Calls read function then updates Adler32/CRC checksum. |
| 0x00E83640 | 558 | png_decompress_chunk | libpng: Decompresses a PNG chunk's data (e.g., zTXt, iCCP). Checks memory limits, inflates data, allocates output buffer. Returns status code (-4=OOM, -7=error, 1=success). |
| 0x00E83870 | 1113 | png_do_expand_pixel_row | libpng: Expands pixel row by replication factor for interlaced image display. Handles 1-bit, 2-bit, 4-bit, and 8+ bit pixel depths. Works in-place from right to left to avoid overwriting source data. |
| 0x00E83CD0 | 77 | png_get_fixed_point_from_buf | libpng: Reads a 4-byte big-endian value from buffer as a PNG fixed-point number. Returns 0xFFFFFFFF and warns if value >= 0x80000000. |
| 0x00E83D20 | 58 | png_get_int_32 | libpng: Reads a 4-byte big-endian signed 32-bit integer from buffer. Handles two's complement for negative values. |
| 0x00E83D60 | 26 | png_get_uint_16 | libpng: Reads a 2-byte big-endian unsigned 16-bit integer from buffer. |
| 0x00E83D80 | 61 | png_get_uint_31 | libpng: Reads a 4-byte big-endian unsigned integer from buffer. Errors if value >= 0x80000000 (must fit in 31 bits). |
| 0x00E83DC0 | 38 | png_get_uint_32 | libpng: Reads a 4-byte big-endian unsigned 32-bit integer from buffer. No range checking. |
| 0x00E83DF0 | 71 | png_handle_IEND | libpng: Handles IEND (image end) chunk. Validates that IHDR and IDAT were seen. Finishes CRC, warns if IEND has data. |
| 0x00E83E40 | 356 | png_handle_IHDR | libpng: Handles IHDR (image header) chunk. Reads 13 bytes: width, height, bit_depth, color_type, compression, filter, interlace. Calculates pixel depth and row bytes. Must be exactly 13 bytes. |
| 0x00E83FB0 | 535 | png_handle_PLTE | libpng: Handles PLTE (palette) chunk. Reads RGB triplets (max 256), validates against bit depth. Resets tRNS/hIST/bKGD if they precede PLTE. |
| 0x00E841D0 | 629 | png_handle_bKGD | libpng: Handles bKGD (background color) chunk. Reads palette index (color type 3) or gray/RGB values. Validates against bit depth and palette size. |
| 0x00E84450 | 501 | png_handle_cHRM | libpng: Handles cHRM (chromaticity) chunk. Reads 8 fixed-point values (white point and RGB primaries xy). Must be 32 bytes, before PLTE/IDAT. |
| 0x00E84650 | 349 | png_handle_eXIf | libpng: Handles eXIf (EXIF metadata) chunk. Reads EXIF data, validates byte order marker (II or MM). Stores raw EXIF data on info struct. |
| 0x00E847B0 | 158 | png_handle_gAMA | libpng: Handles gAMA (gamma) chunk. Reads 4-byte fixed-point gamma value. Must be before PLTE/IDAT. Updates colorspace gamma and copies to info. |
| 0x00E84850 | 339 | png_handle_hIST | libpng: Handles hIST (histogram) chunk. Reads 16-bit frequency counts for each palette entry. Must appear after PLTE and before IDAT. |
| 0x00E849B0 | 1396 | png_handle_iCCP | libpng: Handles iCCP (ICC color profile) chunk. Reads profile name, decompresses ICC profile data, validates and stores on info struct. Updates colorspace. |
| 0x00E84F30 | 539 | png_handle_iTXt | libpng: Handles iTXt (international text) chunk. Reads keyword, compression flag/method, language, translated keyword, and text. Supports compressed and uncompressed text. |
| 0x00E85150 | 390 | png_handle_oFFs | libpng: Handles oFFs (image offset) chunk. Reads 9 bytes: two 32-bit signed offsets (x,y) and 1-byte unit type. Must be before IDAT. |
| 0x00E852E0 | 611 | png_handle_pCAL | libpng: Handles pCAL (calibration of pixel values) chunk. Reads calibration name, x0/x1 min/max, equation type, parameter count, unit name, and parameter strings. |
| 0x00E85550 | 305 | png_handle_pHYs | libpng: Handles pHYs (physical pixel dimensions) chunk. Reads 9 bytes: pixels per unit X, pixels per unit Y, unit type. Must be before IDAT. |
| 0x00E85690 | 365 | png_handle_sBIT | libpng: Handles sBIT (significant bits) chunk. Reads per-channel significant bit counts. Validates values are non-zero and within bit depth range. Must be before PLTE/IDAT. |
| 0x00E85800 | 506 | png_handle_sCAL | libpng: Handles sCAL (physical scale) chunk. Reads unit type (1=meter, 2=radian) and width/height as ASCII strings. Validates numeric format and positive values. |
| 0x00E85A00 | 660 | png_handle_sPLT | libpng: Handles sPLT (suggested palette) chunk. Reads palette name, sample depth (8 or 16), and RGBA+frequency entries. Supports 8-bit (6 bytes/entry) and 16-bit (10 bytes/entry) formats. |
| 0x00E85CA0 | 205 | png_handle_sRGB | libpng: Handles sRGB (standard RGB) chunk. Reads 1-byte rendering intent. Must be before PLTE/IDAT. Updates colorspace sRGB intent. |
| 0x00E85D70 | 309 | png_handle_tEXt | libpng: Handles tEXt (uncompressed text) chunk. Reads keyword and text string. Uses chunk cache limit for text chunks. |
| 0x00E85EB0 | 268 | png_handle_tIME | libpng: Handles tIME (timestamp) chunk. Reads 7 bytes: year (2 bytes big-endian), month, day, hour, minute, second. Can appear after IDAT. |
| 0x00E85FC0 | 518 | png_handle_tRNS | libpng: Handles tRNS (transparency) chunk. For palette images reads alpha bytes, for grayscale reads 2 bytes, for RGB reads 6 bytes. Sets transparent color values on png_struct. |
| 0x00E861D0 | 362 | png_handle_as_unknown | libpng: Handles unknown/unrecognized chunks. Calls user callback if set, otherwise stores chunk data. Manages chunk cache limits. Errors on unhandled critical chunks. |
| 0x00E86340 | 505 | png_handle_zTXt | libpng: Handles zTXt (compressed text) chunk. Reads keyword, compression method (must be 0), decompresses text. Can appear after IDAT. |
| 0x00E86540 | 331 | png__decompress_chunk | PNG library: decompresses a chunk using zlib inflate. Manages zstream state at offsets 0x80-0x94. Loops calling png_zlib_inflate until complete. Handles both caller-provided and stack-local 1KB output buffers. Returns zlib error code. |
| 0x00E86690 | 295 | png_zlib_inflate_init | libpng: Initializes or resets zlib inflate stream. Closes previous stream if in use, then calls inflateInit2 or inflateReset. Sets up decompression for reading PNG data. |
| 0x00E867C0 | 256 | png_inflate_read | libpng: Reads and inflates compressed chunk data in a loop. Feeds input from CRC-read buffer, inflates into output buffer. Used by decompress_chunk for non-IDAT compressed data. |
| 0x00E868C0 | 75 | png_init_filter_functions | libpng: Initializes row filter function pointers. Sets up sub, up, avg, and paeth filter handlers. Uses 1-byte paeth for 8-bit pixel depth, multi-byte paeth otherwise. |
| 0x00E86910 | 443 | png_read_IDAT_data | libpng: Reads and decompresses IDAT (image data) chunks. Chains consecutive IDAT chunks, inflates data into row buffer. Detects end of image data and validates completeness. |
| 0x00E86AD0 | 145 | png_read_buffer | libpng: Gets or allocates a read buffer of at least param_2 bytes. Reuses existing buffer if large enough, otherwise frees and reallocates. param_3: error level (0=fatal, 1=warning, 2=return null). |
| 0x00E86B70 | 160 | png_read_chunk_header | libpng: Reads a PNG chunk header (8 bytes: 4-byte length + 4-byte type). Validates chunk name and length. Initializes CRC for the chunk. Returns chunk data length. |
| 0x00E86C10 | 62 | png_read_filter_row | libpng: Dispatches row filter reversal based on filter type (1=sub, 2=up, 3=avg, 4=paeth). Initializes filter function pointers on first call. |
| 0x00E86C50 | 94 | png_read_filter_row_avg | libpng: Reverses PNG Average filter. Each byte is predicted as floor((left + above)/2). First bpp bytes use above/2, remaining use (left+above)/2. |
| 0x00E86CB0 | 193 | png_read_filter_row_paeth_1byte | libpng: Reverses PNG Paeth filter for 1-byte-per-pixel. Implements Paeth predictor: chooses closest of left/above/upper-left neighbors based on absolute differences. |
| 0x00E86D80 | 238 | png_read_filter_row_paeth_multi | libpng: Reverses PNG Paeth filter for multi-byte pixels. First bpp bytes use above row only, then applies full Paeth predictor with left/above/upper-left neighbors. |
| 0x00E86E70 | 55 | png_read_filter_row_sub | libpng: Reverses PNG Sub filter. Each byte after the first bpp bytes has the value of the byte bpp positions to the left added to it. |
| 0x00E86EB0 | 153 | png_read_filter_row_up | libpng: Reverses PNG Up filter. Each byte has the corresponding byte from the previous row added to it. Unrolled to process 64 bytes at a time for performance. |
| 0x00E86F50 | 113 | png_read_finish_IDAT | libpng: Finishes reading IDAT data. Consumes any remaining compressed data, closes the last IDAT chunk CRC. Called when all image rows have been read. |
| 0x00E86FD0 | 234 | png_push_have_row | libpng: Advances to next row after a row is decoded. For interlaced images, cycles through Adam7 passes (0-6) updating row/col counts per pass. Finishes IDAT when all passes complete. |
| 0x00E870C0 | 158 | png_read_sig | libpng: Reads and validates the 8-byte PNG signature. Checks for valid PNG magic bytes and detects ASCII conversion corruption. |
| 0x00E87160 | 748 | png_read_start_row | libpng: Initializes row reading. Applies transforms to calculate final pixel depth, allocates row buffers (current + previous), sets up interlace pass dimensions. Initializes zlib inflate for IDAT. |
| 0x00E87450 | 77 | png_zlib_inflate | libpng: Calls zlib inflate(). Before first inflate, checks window size in zlib header. Returns zlib status code. |
| 0x00E874A0 | 23 | png_default_flush | libpng: Default flush callback. Calls fflush on the output FILE*. |
| 0x00E874C0 | 49 | png_default_write_data | libpng: Default write callback. Calls fwrite to output data. Errors on short write. |
| 0x00E87500 | 24 | png_write_flush | libpng: Calls the user-provided flush callback if set. |
| 0x00E87520 | 80 | png_set_write_fn | libpng: Sets write callback, flush callback, and IO pointer. Defaults to png_default_write_data and png_default_flush if NULL. Warns if read fn was set. |
| 0x00E87570 | 30 | png_write_data | libpng: Calls the user-provided write callback. Errors if write function is NULL. |
| 0x00E87590 | 346 | png_do_pack | libpng: Packs expanded pixel data back to sub-byte bit depths (1, 2, 4 bit). Used during write when bit depth was expanded for processing. Only for 8-bit color type 1 channel. |
| 0x00E876F0 | 620 | png_do_shift | libpng: Applies bit shift transformation during write. Shifts pixel values based on sBIT significant bits info. Handles sub-byte, 8-bit, and 16-bit depths per channel. |
| 0x00E87960 | 146 | png_do_invert_alpha | libpng: Inverts alpha channel (255-alpha) for RGBA/GA color types. Handles 8-bit and 16-bit per channel. |
| 0x00E87A00 | 287 | png_do_swap_alpha | libpng: Swaps alpha channel position (ARGB<->RGBA, AG<->GA) during write. Handles 8-bit and 16-bit per channel for color types 4 and 6. |
| 0x00E87B20 | 310 | png_do_write_transformations | libpng: Applies all write transformations in order: user transform, quantize, BGR swap, pack, shift, byte swap, bit packing, swap alpha, invert alpha, BGR swap, interlace handling. |
| 0x00EAA1D0 | 249 | ZipWriter__init_state | Initializes ZipWriter internal state. Sets up callback table pointers, compression parameters, and deflate state offsets. Configures entry list (0xf7c), output stream (0xf80), and deflate match parameters at large offsets (0x1af18+). |
| 0x00EAA2D0 | 1495 | ZipWriter__add_entry | Adds an entry to a zip archive. Handles 4 source types: (1) file handle, (2) open file by name, (3) memory buffer, (4) directory entry. Normalizes path separators, writes local file header, compresses/stores data, then appends entry to linked list. Uses ZipEntry/ZipFile helpers. |
| 0x00EAA8B0 | 211 | ZipWriter__write_central_directory | Writes the zip central directory. Iterates through all entries in the linked list, writes each central directory header, frees entry memory, then writes the end-of-central-directory record. Returns 0 on success, 0x400 on write error. |
| 0x00EAA990 | 23 | ZipWriter__set_total_size_if_new | Sets the total zip size at offset 0x6afa4 only if param_2 flag is zero (first time). Used to record final archive size for memory-based zip output. |
| 0x00EAA9B0 | 95 | ZipWriter__finalize_and_close | Finalizes and closes the ZipWriter. Flushes the central directory if not already done, unmaps memory-mapped file view, closes file mapping handle and file handle. Returns accumulated error code. |
| 0x00EAAA10 | 106 | ZipWriter__close_and_free | Closes a zip handle and frees its memory. Validates state==2, calls ZipWriter__finalize_and_close, then frees the inner buffer (0x4078 bytes) and outer handle (8 bytes). Stores result in global DAT_0173eca0. |
| 0x00EAAA80 | 397 | ZipWriter__open_output | Opens a zip output destination. Supports 3 modes: (1) duplicate existing handle, (2) create new file via CreateFileA, (3) create memory-mapped file. Sets up file type detection and initial file position. Returns 0 on success. |
| 0x00EAAC10 | 170 | ZipWriter__create_handle | Creates a new ZipWriter handle. Allocates a 0x4078-byte state buffer, initializes fields, opens the output via ZipWriter__open_output, then wraps in an 8-byte handle struct with state=2. Returns NULL on failure. |
| 0x00EAB0B0 | 63 | ZipWriter__get_sizes | Gets zip archive sizes. Finalizes central directory if not done, then returns compressed size (offset 0x18) and total written size (offset 0x10) via output parameters. Returns 0x20000 if no data was written. |
| 0x00EAB1F0 | 207 | ZipWriter__add_file_entry | Adds a file entry to the zip archive. Validates handle state, copies path to local buffer, then delegates to ZipWriter__add_entry. For mode 2 (file path), makes a local copy of the path string first. Stores result in global DAT_0173eca0. |
| 0x00EAB2C0 | 92 | ZipWriter__get_memory_size | Gets the memory size of a completed zip archive. Validates handle, then calls ZipWriter__get_sizes to retrieve compressed and total sizes. Returns 0x10000 if handle is NULL, 0x80000 if not in valid state. |
| 0x00EAB320 | 75 | deflate__init_match_params | Initializes deflate match parameters in the deflate state structure. Sets lookahead start, previous match, hash insert position, and clears match counters at offsets 0x1af54-0x1af6c. |
| 0x00EAB370 | 37 | deflate__bit_reverse | Reverses the bit order of a value. Takes a value and bit count, returns the value with bits reversed. Used in Huffman code generation (bi_reverse in zlib). |
| 0x00EAB3A0 | 220 | deflate__flush_bit_buffer | Flushes the bit buffer (bi_windup in zlib). Writes remaining bits from the bit accumulator to the output buffer, handles byte alignment, and resets bit counters. Aligns total bits to next 8-bit boundary. |
| 0x00EAB480 | 239 | deflate__build_bl_tree | Builds the bit-length tree for encoding literal/distance tree headers (build_bl_tree in zlib). Scans bit length frequencies to determine optimal tree size. Returns max index of non-zero bit length codes. Updates total bit count. |
| 0x00EAB570 | 522 | deflate__build_huffman_tree | Builds optimal Huffman tree from frequency data (build_tree in zlib). Uses heap-based algorithm with pqdownheap to construct the tree, then calls gen_bitlen and gen_codes to generate optimal bit lengths and codes. |
| 0x00EAB780 | 352 | deflate__compress_block | Compresses a block using the given literal and distance Huffman trees (compress_block in zlib). Iterates through the match buffer, encoding literals and length/distance pairs. Writes END_BLOCK code at the end. |
| 0x00EAB8E0 | 328 | deflate__copy_stored_block | Copies a stored (uncompressed) block to the output (copy_block in zlib). Flushes bit buffer, writes block length and complement, then copies raw data via memcpy. Updates total bit count. |
| 0x00EABA30 | 240 | zlib_crc32 | Computes CRC32 checksum using a lookup table at DAT_011bf178. Processes data in 8-byte unrolled chunks for performance, then handles remaining bytes individually. Returns the CRC32 value. |
| 0x00EABB20 | 786 | deflate__init_trees | Initializes static and dynamic Huffman trees for deflate compression (ct_init in zlib). Builds length/distance code lookup tables, initializes static literal tree (fixed 7/8/9 bit codes), static distance tree (fixed 5-bit codes), and calls init_block. Only runs once (guarded by static flag at offset 0xe7e). |
| 0x00EABE40 | 487 | deflate__tally_match | Records a literal or length/distance match pair (ct_tally in zlib). If dist==0, records a literal byte. Otherwise records a match with distance and length, updating frequency counters for literal, length, and distance trees. Returns 1 if the block buffer is full and should be flushed. |
| 0x00EAC030 | 841 | deflate__lazy_match | Deflate compression with lazy matching strategy (deflate_slow in zlib). For compression levels >= 4, uses two-pass matching: first finds a match, then checks if the next position has a better match before committing. Emits literals or match pairs via tally, and flushes blocks when full. Falls back to deflate_fast for lower levels. |
| 0x00EAC380 | 590 | deflate__fast_match | Deflate compression with fast matching strategy (deflate_fast in zlib). For each position, finds the longest match and immediately emits it. Inserts hash entries for matched bytes. Flushes blocks when tally returns full. Simpler but less optimal than lazy matching. |
| 0x00EAC6A0 | 353 | deflate__fill_window | Fills the sliding window buffer with input data (fill_window in zlib). When the window position exceeds 0x7efa, slides the window by copying the upper half to the lower half and adjusting hash chains. Reads more input data via the read callback until lookahead >= 262 bytes or EOF. |
| 0x00EAC810 | 441 | deflate__flush_block | Flushes a deflate block to the output (flush_block in zlib). Determines whether to emit a stored block, static Huffman block, or dynamic Huffman block based on which has the smallest output size. Builds trees, compresses the block, and returns the compressed size in bytes. |
| 0x00EAC9D0 | 518 | deflate__gen_bitlen | Generates optimal bit lengths for a Huffman tree (gen_bitlen in zlib). Enforces max code length constraint by redistributing bits from longer codes. Computes opt_len and static_len cost estimates for the tree. |
| 0x00EACBE0 | 170 | deflate__gen_codes | Generates Huffman codes from bit lengths (gen_codes in zlib). Computes starting code for each bit length, then assigns reversed bit codes to each symbol. Verifies total code count consistency. |
| 0x00EACDC0 | 148 | deflate__init_block | Resets frequency counters for a new deflate block (init_block in zlib). Clears all 286 literal/length frequencies, 30 distance frequencies, and 19 bit-length frequencies. Resets opt_len, static_len, match/literal counts. Sets END_BLOCK frequency to 1. |
| 0x00EACED0 | 322 | deflate__set_compression_level | Sets deflate compression level parameters (lm_init in zlib). Validates level 1-8, clears hash table, loads configuration (max_lazy, good_match, nice_match, max_chain) from a config table. Reads initial input into the window buffer and initializes the hash function. |
| 0x00EAD020 | 495 | deflate__longest_match | Finds the longest matching string in the hash chain (longest_match in zlib). Compares bytes at the current position with candidates from the hash chain, using 8-byte unrolled comparison. Follows hash chain up to max_chain_length links. Returns the match length (up to 258 bytes). Updates match position in the state. |
| 0x00EAE020 | 242 | deflate__scan_tree_frequencies | Scans a Huffman tree and counts bit-length code frequencies (scan_tree in zlib). Processes the tree to count runs of equal bit lengths, zero-length codes, and repeated codes. Updates bit-length frequency counters for encoding the tree structure in the compressed output. |
| 0x00EAE120 | 215 | deflate__send_all_trees | Sends all three Huffman tree headers for a dynamic block (send_all_trees in zlib). Writes literal count, distance count, and bit-length count as 5/5/4 bit fields. Sends bit-length tree codes, then sends literal and distance trees using the bit-length tree. |
| 0x00EAE200 | 192 | deflate__send_bits | Sends bits to the output buffer (send_bits in zlib). Accumulates bits in a 16-bit buffer, flushing 2 bytes to output when the buffer exceeds 16 bits. Validates bit length is 1-15. Updates total bit count. |
| 0x00EAE2C0 | 389 | deflate__send_tree | Sends a Huffman tree as a sequence of bit-length codes (send_tree in zlib). Encodes runs of equal lengths, zero-length codes (repeat counts 3-10 and 11-138), and consecutive equal codes (repeat count 3-6). Uses the bit-length tree for encoding. |
| 0x00EAE450 | 170 | deflate__set_data_type | Determines if data is binary or text (set_data_type in zlib). Sums frequencies of control characters vs ASCII characters. If control character frequencies exceed 1/4 of ASCII frequencies, sets the data type flag to binary (1), else text (0). |
| 0x00EAE500 | 41 | deflate__flush_write_callback | Deflate output flush callback. If pending output bytes > 0, writes them to the output stream and resets the pending count to 0. Used as the flush callback in the deflate compression pipeline. |
| 0x00EAE530 | 21 | deflate__read_input_callback | Deflate input read callback. Thin wrapper that calls ZipEntry__read_data to read from the ZIP entry source. Passes through the buffer and returns bytes read. |
| 0x00EAE550 | 26 | deflate__write_output_callback | Deflate output write callback. If size > 0, writes data to the ZIP output stream via ZipEntry__write_data. Thin wrapper used in deflate compression pipeline. |
No function here matches that. Search all 47,061 functions instead.