I would say a good rule of thumb for ported boxes and sub vents alike...keep them from any obstructions at least the same length as the vent is wide. So if you have a sub with a vent of say an inch or so, keep the back of the vent at least 1 inch from any obstructions so and so forth. Same with ported boxes depending on the way you port it.