« first day (3915 days earlier)      last day (1095 days later) » 

10:11 PM
What should I search for if I want to load a part of an image as a texture, not the whole thing
and I want to decide which part to load programatically
 
 
1 hour later…
11:19 PM
Oof. That gets complicated depending on your file format, @MeetTaraviya
Some file formats like BMP or TGA (often) have predictable file layouts. GPU-compressed formats in particular are designed so that if you know what part of the image you want to read, you can immediately jump to the exact bytes that matter, skipping over the rest.
But common file formats in more everyday use, like JPEG or PNG, don't have this property. The exact byte offset of a particular pixel can depend on how well the pixels before it in the file managed to compress. If the data before it was very compressible, it might move earlier in the file. If the compressor wasn't able to reduce the preceding data much or at all, it might move later.
So for those formats, you don't have much choice other than to load the whole thing.
What can you tell us about your use case? What engine, framework, or language are you using? Where do these image files come from? How do you decide what part you want to load? These kinds of details can help us suggest effective solutions.
 

« first day (3915 days earlier)      last day (1095 days later) »