you must look both ways before crossing the street中crossing的用法

问题描述:

you must look both ways before crossing the street中crossing的用法
这里crossing是动词的ing形式么?还是做了所谓的动名词,要是做了动名词,那the road不就多余了么?还是crossing作了这个状语从句中的从句成分,所以它的动词必须用ing形式?

before 在这里是介词“在..之前”,介词后加动词ing形式,既:动名词
如:Thanks for helping me.
you must look both ways before crossing the street
在你过路之前要两边的路都要看看.