Building an 8 to 4 Encoder from a 8 to 4 Multiplexer?
First of all, the 74HC4052 is not an 8-to-4 multiplexer, it is a dual 4-to-1 multiplexer with common select inputs.

If I understand correctly, you want to connect a total of 8 switches, four at a time, to your microcontroller. You would need two of these chips in order to do that.

However, you could connect them two at a time to your microcontroller with just one of these chips.