Calculate the single-particle total (i.e. k-integrated) density of states, and then plot it. The same function can be used to calculate the relevant chemical potential (this quantity is required for establishing the relevant band gap).
Assuming the output band structure file provides you with the band-structure as a function of the K-point coordinate, and a K-point path along the high symmetry-lines of your structure is followed, you just plot the band structure. Then find the points where you have the direct (single k-point where maximum of valence and minimum of conduction band arise) and indirect (two k-points where one is located at the maximum of the valence band and one at the minimum of the conduction band) band gaps, and calculate the band gaps as the difference in energy of the valence and conduction band provided in your band structure plot.
The Method presented by Behnam Farid on the other hand will give you the Density of States (DOS), where you will find the global band gap (i.e. the smallest of the direct and indirect band gap)