Update of /cvsroot/dirac/compress/libdirac_byteio
In directory
sc8-pr-cvs12.sourceforge.net:/tmp/cvs-serv26219/libdirac_byt
eio
Modified Files:
displayparams_byteio.cpp displayparams_byteio.h
Log Message:
Spec Compliance - nomenclature changes. Rename aspect_ratio
to
pixel_aspect_ratio, sampling_format to
chroma_sampling_format.
Index: displayparams_byteio.h
============================================================
=======
RCS file:
/cvsroot/dirac/compress/libdirac_byteio/displayparams_byteio
.h,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** displayparams_byteio.h 7 Nov 2007 06:35:48 -0000 1.3
--- displayparams_byteio.h 15 Jan 2008 04:36:23 -0000 1.4
***************
*** 95,106 ****
/**
! * Reads Sampling Format
*/
! void InputSamplingFormat();
/**
! * Reads aspect ratio info
*/
! void InputAspectRatio();
/**
--- 95,106 ----
/**
! * Reads Chroma Sampling Format
*/
! void InputChromaSamplingFormat();
/**
! * Reads pixel aspect ratio info
*/
! void InputPixelAspectRatio();
/**
***************
*** 150,161 ****
/**
! * Outputs Sampling Format
*/
! void OutputSamplingFormat();
/**
! * Outputs aspect ratio info
*/
! void OutputAspectRatio();
/**
--- 150,161 ----
/**
! * Outputs Chroma Sampling Format
*/
! void OutputChromaSamplingFormat();
/**
! * Outputs pixel aspect ratio info
*/
! void OutputPixelAspectRatio();
/**
Index: displayparams_byteio.cpp
============================================================
=======
RCS file:
/cvsroot/dirac/compress/libdirac_byteio/displayparams_byteio
.cpp,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** displayparams_byteio.cpp 9 Jan 2008 10:44:13 -0000 1.8
--- displayparams_byteio.cpp 15 Jan 2008 04:36:23 -0000 1.9
***************
*** 63,68 ****
InputFrameSize();
! // input sampling format
! InputSamplingFormat();
// input scan format
--- 63,68 ----
InputFrameSize();
! // input chroma sampling format
! InputChromaSamplingFormat();
// input scan format
***************
*** 72,77 ****
InputFrameRate();
! // input aspect ratio
! InputAspectRatio();
// input clean area
--- 72,77 ----
InputFrameRate();
! // input pixel aspect ratio
! InputPixelAspectRatio();
// input clean area
***************
*** 87,95 ****
void SourceParamsByteIO::Output()
{
! // input frame dimensions
OutputFrameSize();
! // input sampling format
! OutputSamplingFormat();
// output scan format
--- 87,95 ----
void SourceParamsByteIO::Output()
{
! // output frame dimensions
OutputFrameSize();
! // output chroma sampling format
! OutputChromaSamplingFormat();
// output scan format
***************
*** 99,104 ****
OutputFrameRate();
! // output aspect ratio
! OutputAspectRatio();
// output clean area
--- 99,104 ----
OutputFrameRate();
! // output pixel aspect ratio
! OutputPixelAspectRatio();
// output clean area
***************
*** 127,131 ****
}
! void SourceParamsByteIO::InputSamplingFormat()
{
bool chroma_flag = ReadBool();
--- 127,131 ----
}
! void SourceParamsByteIO::InputChromaSamplingFormat()
{
bool chroma_flag = ReadBool();
***************
*** 144,165 ****
}
! void SourceParamsByteIO::InputAspectRatio()
{
! bool aspect_ratio_flag = ReadBool();
! if(!aspect_ratio_flag)
return;
// read index value
! int aspect_ratio_index = ReadUint();
! AspectRatioType
aspect_ratio=IntToAspectRatioType(aspect_ratio_index);
! if(aspect_ratio==ASPECT_RATIO_UNDEFINED)
DIRAC_THROW_EXCEPTION(
! ERR_INVALID_ASPECT_RATIO,
! "Dirac does not recognise the
specified aspect-ratio",
SEVERITY_ACCESSUNIT_ERROR)
! if(aspect_ratio_index!=ASPECT_RATIO_CUSTOM)
{
! m_src_params.SetAspectRatio(aspect_ratio);
}
else
--- 144,165 ----
}
! void SourceParamsByteIO::InputPixelAspectRatio()
{
! bool pixel_aspect_ratio_flag = ReadBool();
! if(!pixel_aspect_ratio_flag)
return;
// read index value
! int pixel_aspect_ratio_index = ReadUint();
! PixelAspectRatioType
pixel_aspect_ratio=IntToPixelAspectRatioType(pixel_aspect_ra
tio_index);
! if(pixel_aspect_ratio==PIXEL_ASPECT_RATIO_UNDEFINED)
DIRAC_THROW_EXCEPTION(
! ERR_INVALID_PIXEL_ASPECT_RATIO,
! "Dirac does not recognise the
specified pixel_aspect_ratio",
SEVERITY_ACCESSUNIT_ERROR)
!
if(pixel_aspect_ratio_index!=PIXEL_ASPECT_RATIO_CUSTOM)
{
!
m_src_params.SetPixelAspectRatio(pixel_aspect_ratio);
}
else
***************
*** 168,172 ****
int numerator = ReadUint();
int denominator = ReadUint();
! m_src_params.SetAspectRatio(numerator,
denominator);
}
--- 168,172 ----
int numerator = ReadUint();
int denominator = ReadUint();
! m_src_params.SetPixelAspectRatio(numerator,
denominator);
}
***************
*** 330,334 ****
}
! void SourceParamsByteIO::OutputSamplingFormat()
{
// output 'is default' flag
--- 330,334 ----
}
! void SourceParamsByteIO::OutputChromaSamplingFormat()
{
// output 'is default' flag
***************
*** 345,352 ****
! void SourceParamsByteIO::OutputAspectRatio()
{
! if (m_src_params.AspectRatioIndex()!=
ASPECT_RATIO_CUSTOM
! && m_src_params.AspectRatioIndex() ==
m_default_src_params.AspectRatioIndex())
{
// default frame rate index
--- 345,352 ----
! void SourceParamsByteIO::OutputPixelAspectRatio()
{
! if (m_src_params.PixelAspectRatioIndex()!=
PIXEL_ASPECT_RATIO_CUSTOM
! && m_src_params.PixelAspectRatioIndex() ==
m_default_src_params.PixelAspectRatioIndex())
{
// default frame rate index
***************
*** 358,367 ****
// Frame rate index
! WriteUint(m_src_params.AspectRatioIndex());
! if (!m_src_params.AspectRatioIndex()) // i,e. custom
value
{
! WriteUint(m_src_params.AspectRatio().m_num);
! WriteUint(m_src_params.AspectRatio().m_denom);
}
}
--- 358,367 ----
// Frame rate index
! WriteUint(m_src_params.PixelAspectRatioIndex());
! if (!m_src_params.PixelAspectRatioIndex()) // i,e.
custom value
{
! WriteUint(m_src_params.PixelAspectRatio().m_num);
!
WriteUint(m_src_params.PixelAspectRatio().m_denom);
}
}
------------------------------------------------------------
-------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216
239;13503038;w?http://sf.net/marketplace
_______________________________________________
Dirac-commits mailing list
Dirac-commits lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dirac-com
mits
|