The fact you wrote “perhaps prevent” is why the study is absolutely needed, if masks ever come back they’re going to get the same (if not much more) pushback as before, being able to say “masks are scientifically proven to prevent infection by x%” will get a much better use rate than “masks may perhaps prevent…”.
The major resistance to masks from day 1 has been that no one has provided scientific evidence of how well they work. If it’s 1% many people still won’t think they are worth the discomfort but if they can show it’s something substantial like 20% most people, even anti-maskers, will get on board.
That kind of study sounds like what you would expect for a vaccine or a new drug. But for masking, there are too many factors that researchers could not fully control that make such a precise figure impossible to collect accurately, such as:
1) What type of masks people wear
2) Whether they wear their mask correctly and whether they report on their own mask use accurately. Clinical trial investigators can't follow around subjects all the time to make sure, so they'd likely have to rely on self-reported use.
3) What activities they do and whether they're exposed to COVID while doing them. In real-world conditions, that would be impossible to know. Or maybe they're never exposed at all, which wouldn't prove whether a mask worked or not, same reason why vaccine trials largely avoided participants that worked at home and didn't go anywhere back in 2020.
4) People will behave differently when they're masked vs. unmasked in ways that could affect their exposure. Drug and vaccine trials get around this with placebos, but obviously there's no mask version of a placebo.
5) Are they exposed to COVID in situations where they, understandably, removed their mask, like dining out? If a person who reported wearing their mask correctly caught COVID in that situation, it may incorrectly look like the mask didn't work.
6) All of these same factors would apply to people in the same household, who could then spread COVID to a person in the trial at home when they're not wearing masks.
7) Prior immunity, whether through infection or vaccination, would now affect whether an exposed person gets infected.
Another key point: masks had enough evidence from experimental studies and studies in health care spaces to show that they do reduce spread. Because they are also a harmless intervention that could be rapidly adopted by nearly everyone, the benefit needed to justify the risk is basically anything more than zero. So it made sense to use them even without being able to say it's "X% effective," as long as there was a threat of overwhelming hospitals.