First, your declaration of "rows" and "cols" as for loop indices shadows the parameters of the same name.
Second, I would strongly recommend passing the matrix by const reference to the function, as the overhead of copying the whole thing onto the stack when the function is called is significant.
1 2 3 4 5
void display( vector< vector<bool> > const& g, int rows, int cols ) {
for( int r = 0; r < rows; ++r )
for( int c = 0; c < cols; ++c )
cout << g.at( r ).at( c ) << endl;
}