There are various ways Ecco can gain infinite oxygen. When Ecco has this ability, his oxygen bar will disappear from the screen and he can stay underwater forever. Ecco can temporarily gain infinite oxygen through the use of an Invincibility Glyph. However this only lasts for a short period of time.
In Ecco the Dolphin, Ecco will be granted this ability permanently by the Asterite towards the end of the game. At the start of Ecco: The Tides of Time, Ecco retains this ability, however, he soon loses it in the Fault Zone level when the Asterite is destroyed by the Vortex Queen. However, late in the game he is again granted this ability by the Asterite.