Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(2)  |  Call(2)  |  Derive(0)  |  Import(0)
Get MPEG version from header bits.

:param bits: Two version bits in MPEG header.
:type bits: int

:return: MPEG Version, one of the following values: ``"2.5", "2", "1"``. 
:rtype: string

:todo: Ponder about the usefulness of this being string. Same with
    :func:`get_layer`(more...)

        def get_mpeg_version(bits):
    """Get MPEG version from header bits.
    
    :param bits: Two version bits in MPEG header.
    :type bits: int
    
    :return: MPEG Version, one of the following values: ``"2.5", "2", "1"``. 
    :rtype: string
    
    :todo: Ponder about the usefulness of this being string. Same with
        :func:`get_layer`
    
    :raise mpeg1audio.MPEGAudioHeaderException: Raised when layer cannot be
        determined.
    
    """

    try:
        return MPEG_VERSIONS[bits]
    except (KeyError, IndexError):
        raise MPEGAudioHeaderException('Unknown MPEG version.')
        


src/m/p/mpeg1audio-0.5.2/src/mpeg1audio/__init__.py   mpeg1audio(Download)
        self = MPEGAudioFrame()
 
        self.version = headers.get_mpeg_version(mpeg_version_bits)
        self.layer = headers.get_layer(layer_bits)
        self.bitrate = headers.get_bitrate(self.version, self.layer,

src/m/p/mpeg1audio-HEAD/src/mpeg1audio/__init__.py   mpeg1audio(Download)
        self = MPEGAudioFrame()
 
        self.version = headers.get_mpeg_version(mpeg_version_bits)
        self.layer = headers.get_layer(layer_bits)
        self.bitrate = headers.get_bitrate(self.version, self.layer,