Class: TagLib::Ogg::PageHeader

Inherits:
Object
  • Object
show all
Defined in:
lib/TagLib_doc.rb

Overview

An implementation of the page headers associated with each Ogg::Page. .

This class implements Ogg page headers which contain the information about Ogg pages needed to break them into packets which can be passed on to the codecs.

Instance Method Summary collapse

Instance Method Details

#absoluteGranularPositionObject

A special value of containing the position of the packet to be interpreted by the codec. In the case of Vorbis this contains the PCM value and is used to calculate the length of the stream.setAbsoluteGranularPosition()



902
903
# File 'lib/TagLib_doc.rb', line 902

def absoluteGranularPosition()
end

#dataSizeObject

Returns the size of the data portion of the page – i.e. the size of the page less the header size.



820
821
# File 'lib/TagLib_doc.rb', line 820

def dataSize()
end

#firstPacketContinuedObject

Some packets can be continued across multiple pages. If the first packet in the current page is a continuation this will return true. If this is page starts with a new packet this will return false.lastPacketCompleted() setFirstPacketContinued()



815
816
# File 'lib/TagLib_doc.rb', line 815

def firstPacketContinued()
end

#firstPageOfStreamObject

This returns true if this is the first page of the Ogg (logical) stream.setFirstPageOfStream()



803
804
# File 'lib/TagLib_doc.rb', line 803

def firstPageOfStream()
end

#isValidObject

Returns true if the header parsed properly and is valid.



860
861
# File 'lib/TagLib_doc.rb', line 860

def isValid()
end

#lastPacketCompletedObject

Returns true if the last packet of this page is completely contained in this page.firstPacketContinued() setLastPacketCompleted()



872
873
# File 'lib/TagLib_doc.rb', line 872

def lastPacketCompleted()
end

#lastPageOfStreamObject

This returns true if this is the last page of the Ogg (logical) stream.setLastPageOfStream()



849
850
# File 'lib/TagLib_doc.rb', line 849

def lastPageOfStream()
end

#packetSizesObject

Ogg pages contain a list of packets (which are used by the contained codecs). The sizes of these pages is encoded in the page header. This returns a list of the packet sizes in bytes.setPacketSizes()



884
885
# File 'lib/TagLib_doc.rb', line 884

def packetSizes()
end

#pageSequenceNumberObject

Returns the index of the page within the Ogg stream. This helps make it possible to determine if pages have been lost.setPageSequenceNumber()



890
891
# File 'lib/TagLib_doc.rb', line 890

def pageSequenceNumber()
end

#renderObject

Render the page header to binary data.The checksum – bytes 22 - 25 – will be left empty and must be filled in when rendering the entire page.



866
867
# File 'lib/TagLib_doc.rb', line 866

def render()
end

#setAbsoluteGranularPosition(agp) ⇒ Object

A special value of containing the position of the packet to be interpreted by the codec. It is only supported here so that it may be coppied from one page to another.absoluteGranularPosition()



809
810
# File 'lib/TagLib_doc.rb', line 809

def setAbsoluteGranularPosition(agp)
end

#setFirstPacketContinued(continued) ⇒ Object

Sets the internal flag indicating if the first packet in this page is continued to continued.firstPacketContinued()



843
844
# File 'lib/TagLib_doc.rb', line 843

def setFirstPacketContinued(continued)
end

#setFirstPageOfStream(first) ⇒ Object

Marks this page as the first page of the Ogg stream.firstPageOfStream()



826
827
# File 'lib/TagLib_doc.rb', line 826

def setFirstPageOfStream(first)
end

#setLastPacketCompleted(completed) ⇒ Object

Sets the internal flag indicating if the last packet in this page is complete to completed.lastPacketCompleted()



896
897
# File 'lib/TagLib_doc.rb', line 896

def setLastPacketCompleted(completed)
end

#setLastPageOfStream(last) ⇒ Object

Marks this page as the last page of the Ogg stream.lastPageOfStream()



878
879
# File 'lib/TagLib_doc.rb', line 878

def setLastPageOfStream(last)
end

#setPacketSizes(sizes) ⇒ Object

Sets the sizes of the packets in this page to sizes. Internally this updates the lacing values in the header.packetSizes()



908
909
# File 'lib/TagLib_doc.rb', line 908

def setPacketSizes(sizes)
end

#setPageSequenceNumber(sequenceNumber) ⇒ Object

Sets the page's position in the stream to sequenceNumber.pageSequenceNumber()



914
915
# File 'lib/TagLib_doc.rb', line 914

def setPageSequenceNumber(sequenceNumber)
end

#setStreamSerialNumber(n) ⇒ Object

Every Ogg logical stream is given a random serial number which is common to every page in that logical stream. This sets this pages serial number. This method should be used when adding new pages to a logical stream.streamSerialNumber()



855
856
# File 'lib/TagLib_doc.rb', line 855

def setStreamSerialNumber(n)
end

#sizeObject

Returns the complete header size.



837
838
# File 'lib/TagLib_doc.rb', line 837

def size()
end

#streamSerialNumberObject

Every Ogg logical stream is given a random serial number which is common to every page in that logical stream. This returns the serial number of the stream associated with this packet.setStreamSerialNumber()



832
833
# File 'lib/TagLib_doc.rb', line 832

def streamSerialNumber()
end