8x8 bitmaps contain 64 bits of data. You can store that in 8 bytes. I don't know where you get your 246 bytes from, GIF? JPG? If you want to store them in a format known by image viewers, I'd go for PBM, which, for 8x8 bitmaps, needs 7 additionaly bytes of overhead: the magic number (P4), and the width and height of the image, each encoded in ASCII. And each of the three pieces of data is followed by whitespace.

But you don't have to store them in a file system (many file systems will use 8k blocks, where each block can be used by at most two files, hence the 4096 bytes you mention. But some file system can subdivide blocks into smaller fragments, and allow you to use smaller blocks as well, but I disgress) - you can store them on a raw disk as well. Using a format (such as P4) that has a fixed size, finding them on a raw disk would be easy.

Of course, even if it was feasable, there's no point in generating and storing each possible image. You might as well generate the images when you need them.


In reply to Re^7: Very Large Hex Combinations by Anonymous Monk
in thread Very Large Hex Combinations by danambroseUK

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.