L3 switch interVLAN

Hi,

I’m not sure if I understand VLAN routing on a level 3 switch level completely.
In Cisco the ‘ip routing’ command just enables routing between all configured vlan’s?
And then you have to close stuff off with ACL’s?

What if I have 3 VLAN’s. and I want host 1a and 1b in VLAN 1 to communicate with host 2a and 2b in VLAN 2.
but no other hosts are supposed to communicate across VLAN’s.
Is the proper way to do this
-enable IP routing
-make an ACL to permit 1a->2a;allow 1a->2b ; deny anything else etc

what am I missing here.

Guide me networking magicians