Example #1
0
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# -------------------------------------------------------------------------

import vorbissimple
import sys
import time

x = vorbissimple.vorbissimple()
f = open("/home/zathras/Documents/Media/Ogg/PopularClassics/2/audio_01.ogg",
         "r", 0)
#f=open("/home/zathras/Documents/Media/Ogg/KR-Tomb-of-Horus.ogg","r",0)
time.sleep(0.01)

while 1:
    try:
        data = x._getAudio()
        sys.stdout.write(data)
        sys.stdout.flush()
    except "RETRY":
        pass
    except "NEEDDATA":
        d = f.read(4096)
        if d == "":
Example #2
0
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# -------------------------------------------------------------------------

import vorbissimple
import sys
import time

x = vorbissimple.vorbissimple()
f = open("/home/zathras/Documents/Media/Ogg/PopularClassics/2/audio_01.ogg", "r", 0)
# f=open("/home/zathras/Documents/Media/Ogg/KR-Tomb-of-Horus.ogg","r",0)
time.sleep(0.01)

while 1:
    try:
        data = x._getAudio()
        sys.stdout.write(data)
        sys.stdout.flush()
    except "RETRY":
        pass
    except "NEEDDATA":
        d = f.read(4096)
        if d == "":
            break
Example #3
0
 def __init__(self):
    """x.__init__(...) initializes x; see x.__class__.__doc__ for signature"""
    super(VorbisDecode, self).__init__()
    self.decoder = vorbissimple.vorbissimple()
Example #4
0
 def __init__(self):
     """x.__init__(...) initializes x; see x.__class__.__doc__ for signature"""
     super(VorbisDecode, self).__init__()
     self.decoder = vorbissimple.vorbissimple()