I've used an in-wall type vent (air valve) for a toilet before instead of venting through the roof. Would it work for a shower?

Thanks in advance for your advice.