Lines Matching defs:page
112 * ogg_sync_state buffers the returned page data, holding at most one
113 * complete page at a time. A returned Ogg page remains valid until any
127 * buffered until a complete page is ready for writing. Pages for writing out
131 * packets when a page is ready to be written out is a caller bug anyways.
142 static void ogg_page_search_continued_data (OGG_PRIVATE *odata, ogg_page *page) ;
158 ** page and check that it contains a codec we support as supporting
185 ** bitstream and no complete page was in the buffer.
199 psf_log_printf (psf, "Error reading first page of Ogg bitstream data\n") ;
204 { /* No page? */
205 psf_log_printf (psf, "Error reading initial header page packet.\n") ;
213 ogg_write_page (SF_PRIVATE *psf, ogg_page *page)
216 bytes = psf_fwrite (page->header, 1, page->header_len, psf) ;
217 bytes += psf_fwrite (page->body, 1, page->body_len, psf) ;
219 return bytes == page->header_len + page->body_len ;
268 ** Skipped -synced bytes before finding the start of a page.
269 ** If seeking, we have just landed in the middle of a page.
280 { psf_log_printf (psf, "Ogg : Skipped %d bytes looking for the next page. Corrupted bitstream?!\n", position) ;
285 { /* Have a page */
384 ** Unpack all the packets on the page. It is undocumented (like much of
385 ** libOgg behavior) but all packets from a page read into the stream are
386 ** guarenteed to remain valid in memory until a new page is read into the
459 { ogg_page page ;
529 ** The ideal case is we see a page that ends before our target followed
530 ** by a page that ends after our target.
535 { ret = ogg_sync_next_page (psf, &page, boundary - seek_pos, &seek_pos) ;
563 ** If we did find a page from another stream or without a
571 /* Found a page. Advance seek_pos past it */
572 seek_pos += page.header_len + page.body_len ;
574 ** Save the offset of the first page we found after the seek,
581 if (odata->ostream.serialno != ogg_page_serialno (&page))
585 ** The Ogg spec says that a page with a granule pos of -1 must not
591 has_packets = ogg_page_packets (&page) > 0 ;
592 gp = has_packets ? ogg_page_granulepos (&page) : -1 ;
596 ogg_stream_pagein (&odata->ostream, &page) ;
599 ** If packets did end on this page, but we still didn't
614 ** We found a page that ends before our target. Advance to
615 ** the raw offset of the next page.
620 /* Save the byte offset of after this page. */
625 if (ogg_page_continues (&page))
626 { ogg_page_search_continued_data (odata, &page) ;
629 ** this page's start, so that if we do wind up having to
632 ** remember the end of the page.
637 ** does not end) on the next page, we still avoid the extra
652 ** Found a page that ends after our target. If we had just
660 ** In later iterations, don't read past the first page we
683 ** If we are buffering, the page we want is currently buffered in the
684 ** Ogg stream structure, or in the Ogg page which has not been submitted.
696 { ret = ogg_sync_next_page (psf, &page, -1, &seek_pos) ;
700 ogg_page_search_continued_data (odata, &page) ;
706 ogg_stream_pagein (&odata->ostream, &page) ;
786 /* Load the first page in the physical bitstream. */
903 ogg_page_search_continued_data (OGG_PRIVATE *odata, ogg_page *page)
904 { ogg_stream_pagein (&odata->ostream, page) ;