Though I wouldn't be bothered to learn this, I think this sort of thing is what the OP is asking about.
if you want to learn about the yogic breathing processes, prepare to take a trip down to hippy town and get your fill of pseudoscience and snake oil. google the various terms and there are multiple instructional videos. yoga studios sometimes will offer dedicated mediation/breathing classes or groups. there's lots of good benefits to meditation and breathing exercises, but if you listen to some people you'd think it'll cure cancer, grow back hair on a bald head, and give you superpowers. i digress...
the overall practice of breath control falls under 'Pranayama'. There are three main practice types, and all are subsets of applied meditation.
'Ujjayi Pranayama'; where the glottis is held slightly open like when you say 'ha' and the mind is focused on the breath and heart. breath is through the nose, full inhales and exhales, with a brief pause between. primarily used during vinyasa yoga practice, with a count of 3~5 seconds per breath. when seated, breath count ranges from 15 to 60+ seconds depending on experience. I find this to be the most useful to practice in regard to SCUBA, as a closed glottis is not a good thing, and increasing lung capacity allows for wider buoyancy control.
'Nadi Shodhana Pranayama', 'alternate nose breathing'; glottis remains slightly open and breath is still through the nose, but each nostril is blocked off in sequence: block left, inhale, exhale, unblock left, block right, inhale, exhale, repeat. again, meditative practice and slowing of the breath, heart, and mind is the process. 10~30 seconds per breath.
'Kapalabhati Pranayama', 'skull shining breath' (seriously); fast, forceful breaths from the belly, about twice a second. used between intervals of Nadi Shodhana and Ujjayi. repeat 25~100x, then return to resting Ujjayi. think of it as high intensity interval training for your lungs and brain. you go from a 'resting' state, to max effort without straining for a minute, then back to 'resting'.
all three of the breathing practices are to be done without straining. attempting to use a 30 second breath cycle on active SCUBA is a good way to retain a bunch of CO2, but being able to mindfully bring your breathing rate down from a panic response is a key skill. stop, breathe properly, think, act.