When it comes to intelligence, this is not something that we can say is actually emergent.
There are currently a number of projects that are looking into intelligence and free-will. There are researchers on the same teams who hold quite different opinions - the results for these projects are not at all conclusive.
I would love to see an actual example where a program does something not encoded in itself already.
1). the code within the systems
2). the data entered into the system.
Those images are the result of how the data is processed by the code. Even if you put in a random number generator, the code processes those numbers based on it internal code constraints.
Now a well designed and built code base may be able to generate every image of the same dimensions. You can certainly write code that can exhaustively generate every possible image, but the question here is whether this exhaustive generation is intelligent.
If you ask for a picture of Shakespeare dressed as Spiderman reading a McDonald's advert on the moon, no one has programmed that and the fact it knows these individual concepts is no different to the fact a human has seen them too.
The laws of physics encode every motion and interaction of every particle.
None of those fundamental laws directly says "water is wet".
> I would love to see an actual example where a program does something not encoded in itself already.
You see it every time you use a machine learning system. Even the simplest models, say a linear regression line in a spreadsheet, "learn" from the data, not from the code.