define render function for each pass

not optimal because need to be wrapped by lambda or std::bind