Not if enough nodes enforce a new set of rules, right?
Miners can pack any valid tx into a block, but nodes are the refs enforcing the rulebook. If a majority of us agrees JPEG spam is out of bounds, we can tweak the official rules and miners have to play ball.