Lines Matching defs:header

84 ** The OggOpus spec includes information on header and granule position
98 ** support any other sample rate there may be, the Opus header includes a field
226 OpusHeader header ;
397 /* Write a header... it is expected. */
465 ** Copy the header page into the binheader so we can use binheader
469 psf->header.end = count ;
516 psf_log_printf (psf, "Opus : Error, extra data in Ogg Opus header.\n") ;
540 if ((error = opus_read_header_packet (psf, &oopus->header, &odata->opacket)))
544 ** The comment header MUST be next. It is one packet, that packet MUST begin
558 return ogg_opus_setup_decoder (psf, oopus->header.input_samplerate) ;
590 oopus->header.channels,
591 oopus->header.nb_streams,
592 oopus->header.nb_coupled,
593 oopus->header.stream_map,
612 psf->sf.channels = oopus->header.channels ;
616 ** The Opus decoder can do our gain for us. The OggOpus header contains a
622 ** Both the header.gain field and the parameter are in the Q7.8 format.
626 opus_multistream_decoder_ctl (oopus->u.decode.state, OPUS_SET_GAIN (oopus->header.gain)) ;
672 { oopus->header.channel_mapping = 0 ;
675 oopus->header.stream_map [0] = 0 ;
676 oopus->header.stream_map [1] = 1 ;
683 oopus->header.stream_map,
690 oopus->header.channel_mapping = 1 ;
694 oopus->header.channel_mapping = 255 ;
700 oopus->header.channel_mapping,
703 oopus->header.stream_map,
713 oopus->header.nb_streams = nb_streams ;
714 oopus->header.nb_coupled = nb_coupled ;
730 ** granulepos rate of 48000Hz needed for header.preskip.
737 oopus->header.preskip = lookahead * oopus->sr_factor ;
749 oopus->buffersize = (1275 * 3 + 7) * oopus->header.nb_streams ;
768 oopus->header.version = 1 ;
769 oopus->header.channels = psf->sf.channels ;
772 oopus->header.gain = 0 ;
778 ** have to take Ogg Page header sizes in to account, not just
791 opus_print_header (psf, &oopus->header) ;
793 psf->header.ptr [0] = 0 ;
794 psf->header.indx = 0 ;
800 psf_binheader_writef (psf, "e112", BHW1 (oopus->header.version), BHW1 (psf->sf.channels), BHW2 (oopus->header.preskip)) ;
806 if (oopus->header.input_samplerate)
807 psf_binheader_writef (psf, "e4", BHW4 (oopus->header.input_samplerate)) ;
812 psf_binheader_writef (psf, "e21", BHW2 (oopus->header.gain), BHW1 (oopus->header.channel_mapping)) ;
815 if (oopus->header.channel_mapping > 0)
816 { psf_binheader_writef (psf, "11", BHW1 (oopus->header.nb_streams), BHW1 (oopus->header.nb_coupled)) ;
817 for (nn = 0 ; nn < oopus->header.channels ; nn++)
818 psf_binheader_writef (psf, "1", BHW1 (oopus->header.stream_map [nn])) ;
821 op.packet = psf->header.ptr ;
822 op.bytes = psf->header.indx ;
828 /* The first page MUST only contain the header, so flush it out now */
832 { psf_log_printf (psf, "Opus : Failed to write header!\n") ;
886 last_granulepos = oopus->pkt_pos + (oopus->sr_factor * oopus->loc) + oopus->header.preskip ;
1087 if (oopus->pkt_pos < (unsigned) oopus->header.preskip)
1088 oopus->loc = SF_MIN ((oopus->header.preskip - (int) oopus->pkt_pos) / oopus->sr_factor, oopus->len) ;
1476 - oopus->header.preskip) / oopus->sr_factor ;
1620 target_gp += oopus->header.preskip ;
1628 if (target_gp >= OGG_OPUS_PREROLL + oopus->u.decode.gp_start + (uint64_t) oopus->header.preskip)
1632 { preroll_gp = oopus->u.decode.gp_start + (uint64_t) oopus->header.preskip ;
1686 return offset - ((oopus->header.preskip + oopus->u.decode.gp_start) / oopus->sr_factor) ;
1747 ** samplerate mid-decode, or to re-write the header for encode,
1753 oopus->header.input_samplerate = *((int *) data) ;
1764 - oopus->header.preskip) / oopus->sr_factor ;
1771 *((int *) data) = oopus->header.input_samplerate ;