We propose a concrete form of a vertex function, which we call O-vertex, for the intersection between an O5-plane and a 5-brane in the topological vertex formalism, as an extension of the work of [1]. Using the O-vertex it is possible to compute the Nekrasov partition functions of 5d theories realized on any 5-brane web diagrams with O5-planes. We apply our proposal to 5-brane webs with an O5-plane and compute the partition functions of pure SO(N) gauge theories and the pure G2 gauge theory. The obtained results agree with the results known in the literature. We also compute the partition function of the pure SU(3) gauge theory with the Chern-Simons level 9. At the end we rewrite the O-vertex in a form of a vertex operator.