Ejemplo n.º 1
0
        /// <summary>
        /// PCMデータの形式を設定する。
        /// </summary>
        public void SetFormat(
            int numChannels,
            int bitsPerSample,
            int validBitsPerSample,
            int sampleRate,
            ValueRepresentationType sampleValueRepresentation,
            long numFrames)
        {
            NumChannels                   = numChannels;
            BitsPerSample                 = bitsPerSample;
            ValidBitsPerSample            = validBitsPerSample;
            SampleRate                    = sampleRate;
            SampleValueRepresentationType = sampleValueRepresentation;
            mNumFrames                    = numFrames;

            if (SampleDataType == PcmDataLib.PcmData.DataType.DoP)
            {
                BitRate = SampleRate * numChannels * 16;
            }
            else
            {
                BitRate = SampleRate * numChannels * validBitsPerSample;
            }

            mSampleLargeArray = null;
            IsLossyCompressed = false;
        }
Ejemplo n.º 2
0
        /// <summary>
        /// PCMデータの形式を設定する。
        /// </summary>
        public void SetFormat(
            int numChannels,
            int bitsPerSample,
            int validBitsPerSample,
            int sampleRate,
            ValueRepresentationType sampleValueRepresentation,
            long numFrames)
        {
            NumChannels                   = numChannels;
            BitsPerSample                 = bitsPerSample;
            ValidBitsPerSample            = validBitsPerSample;
            SampleRate                    = sampleRate;
            SampleValueRepresentationType = sampleValueRepresentation;
            mNumFrames                    = numFrames;

            mSampleArray = null;
        }
Ejemplo n.º 3
0
        /// <summary>
        /// PCMデータの形式を設定する。
        /// </summary>
        public void SetFormat(
            int numChannels,
            int bitsPerSample,
            int validBitsPerSample,
            int sampleRate,
            ValueRepresentationType sampleValueRepresentation,
            long numFrames)
        {
            NumChannels = numChannels;
            BitsPerSample = bitsPerSample;
            ValidBitsPerSample = validBitsPerSample;
            SampleRate = sampleRate;
            SampleValueRepresentationType = sampleValueRepresentation;
            mNumFrames = numFrames;

            mSampleArray = null;
        }