compression algorithms obviously feature heavily, as do short mechanisms for indexing large amounts of data and a deep knowledge of the available libraries on the target system. (That stuff can just be linked in.)
If I were you, I'd start by reverse-engineering your favourite 4k demos; perhaps starting with ones from 7-10 years ago, and working forwards to follow the state of the art as it progresses. Analysing your compiler's output is a good place to start, too, though they tend to optimize for speed rather than for space.
Techniques for embedded programming may also be helpful, given the constraints they operate under regularly.
Might not be quite what you're looking for, but in the same spirit: There are several Java 4k contests. The objective being to create a Java demo or even game (!) that completely fits into a single JAR of max 4096 bytes.
One might argue that Java makes it much easier (since you can use the whole runtime), but it's still impressive (and you are cross-platform and don't need to learn assembler ;)).
发布评论
评论(4)
与此同时,我发现了一个很棒的处理 4K 编码的网站:
IN4K
In the meantime I have found a great website dealing with 4K coding:
IN4K
压缩算法显然具有重要的特点,用于索引大量数据的简短机制以及对目标系统上可用库的深入了解也是如此。 (这些东西可以直接链接进去。)
如果我是你,我会从对你最喜欢的 4k 演示进行逆向工程开始; 或许可以从 7 到 10 年前的技术开始,并不断努力追随最新技术的发展。 分析编译器的输出也是一个很好的起点,尽管它们倾向于优化速度而不是空间。
考虑到嵌入式编程技术经常受到的限制,它们也可能会有所帮助。
compression algorithms obviously feature heavily, as do short mechanisms for indexing large amounts of data and a deep knowledge of the available libraries on the target system. (That stuff can just be linked in.)
If I were you, I'd start by reverse-engineering your favourite 4k demos; perhaps starting with ones from 7-10 years ago, and working forwards to follow the state of the art as it progresses. Analysing your compiler's output is a good place to start, too, though they tend to optimize for speed rather than for space.
Techniques for embedded programming may also be helpful, given the constraints they operate under regularly.
Inigo Quilez 有一些 1K 和 4K 介绍的示例。 你可以从他们身上学到很多东西。 也可以看看他的其他文章。
Alexander Sotirov 的关于 Tiny PE 的文章也很有趣。
Inigo Quilez has some examples of 1K and 4K intros. You can learn a lot from them. Check out his other articles too.
The article on Tiny PE by Alexander Sotirov is interesting too.
可能不完全是您正在寻找的内容,但本着同样的精神:有几场 Java 4k 竞赛。 目标是创建完全适合最大 4096 字节的单个 JAR 的 Java 演示甚至游戏(!)。
参见例如
http://www.mojang.com/notch/j4k/l4kd/
或
http://javaunlimited.net/contests/java4k.php
有人可能会说 Java使它变得更容易(因为您可以使用整个运行时),但它仍然令人印象深刻(并且您是跨平台的,不需要学习汇编程序;))。
Might not be quite what you're looking for, but in the same spirit: There are several Java 4k contests. The objective being to create a Java demo or even game (!) that completely fits into a single JAR of max 4096 bytes.
See e.g.
http://www.mojang.com/notch/j4k/l4kd/
or
http://javaunlimited.net/contests/java4k.php
One might argue that Java makes it much easier (since you can use the whole runtime), but it's still impressive (and you are cross-platform and don't need to learn assembler ;)).