Updating link to change in openSUSE:Factory/dirac revision 7.0
OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/dirac?expand=0&rev=ce53bd4ba6e16b2723f90eac0bf5b00b
This commit is contained in:
parent
20c9889f04
commit
61a59a3108
@ -1,52 +0,0 @@
|
|||||||
From 88fae6224b54ecf92ac6e3ae5083c3f352adc798 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Anuradha Suraparaju <anuradha@hoyle.rd.bbc.co.uk>
|
|
||||||
Date: Fri, 17 Apr 2009 17:47:27 +1000
|
|
||||||
Subject: [PATCH] Fix uninitialised memory read that causes the encoder to crash when using
|
|
||||||
non-overlapping blocks.
|
|
||||||
|
|
||||||
---
|
|
||||||
libdirac_common/mot_comp.cpp | 21 +++++++++++++++------
|
|
||||||
1 files changed, 15 insertions(+), 6 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/libdirac_common/mot_comp.cpp b/libdirac_common/mot_comp.cpp
|
|
||||||
index aa8d37c..e0ec2ff 100644
|
|
||||||
--- a/libdirac_common/mot_comp.cpp
|
|
||||||
+++ b/libdirac_common/mot_comp.cpp
|
|
||||||
@@ -306,6 +306,8 @@ void MotionCompensator::CompensateComponent( Picture* pic ,
|
|
||||||
|
|
||||||
int save_from_row = m_bparams.Ybsep()-m_bparams.Yoffset();
|
|
||||||
|
|
||||||
+ bool row_overlap = ((m_bparams.Yblen() - m_bparams.Ybsep()) > 0);
|
|
||||||
+
|
|
||||||
// unpadded picture dimensions
|
|
||||||
const int x_end_data = pic_data_out.FirstX() + std::min(pic_data_out.LengthX(), pic_size.x );
|
|
||||||
const int y_end_data = pic_data_out.FirstY() + std::min(pic_data_out.LengthY(), pic_size.y );
|
|
||||||
@@ -489,12 +491,19 @@ void MotionCompensator::CompensateComponent( Picture* pic ,
|
|
||||||
//Increment the block vertical position
|
|
||||||
pos.y += m_bparams.Ybsep();
|
|
||||||
|
|
||||||
- // Copy the rows required to motion compensate the next row of block.
|
|
||||||
- // This is usually Yblen-Ybsep rows.
|
|
||||||
- memmove (pic_data[0], pic_data[save_from_row], (m_bparams.Yblen() - save_from_row)*pic_data.LengthX()*sizeof(ValueType));
|
|
||||||
- memset( pic_data[m_bparams.Yblen() - save_from_row], 0, save_from_row*pic_data.LengthX()*sizeof(ValueType) );
|
|
||||||
- save_from_row = m_bparams.Ybsep();
|
|
||||||
-
|
|
||||||
+ if (row_overlap)
|
|
||||||
+ {
|
|
||||||
+ // Copy the rows required to motion compensate the next row of
|
|
||||||
+ // blocks. This is usually Yblen-Ybsep rows.
|
|
||||||
+ memmove (pic_data[0], pic_data[save_from_row], (m_bparams.Yblen() - save_from_row)*pic_data.LengthX()*sizeof(ValueType));
|
|
||||||
+ memset( pic_data[m_bparams.Yblen() - save_from_row], 0, save_from_row*pic_data.LengthX()*sizeof(ValueType) );
|
|
||||||
+ save_from_row = m_bparams.Ybsep();
|
|
||||||
+ }
|
|
||||||
+ else
|
|
||||||
+ {
|
|
||||||
+ // no row overlap. So reset pic_data to 0.
|
|
||||||
+ memset( pic_data[0], 0, m_bparams.Yblen()*pic_data.LengthX()*sizeof(ValueType) );
|
|
||||||
+ }
|
|
||||||
}//yblock
|
|
||||||
|
|
||||||
if ( m_add_or_sub == SUBTRACT)
|
|
||||||
--
|
|
||||||
1.7.0.3
|
|
||||||
|
|
@ -1,22 +0,0 @@
|
|||||||
Index: dirac-1.0.2/libdirac_encoder/quant_chooser.cpp
|
|
||||||
===================================================================
|
|
||||||
--- dirac-1.0.2.orig/libdirac_encoder/quant_chooser.cpp
|
|
||||||
+++ dirac-1.0.2/libdirac_encoder/quant_chooser.cpp
|
|
||||||
@@ -340,7 +340,7 @@ void QuantChooser::SetSkip( CodeBlock& c
|
|
||||||
{
|
|
||||||
for (int i=cblock.Xstart(); i<cblock.Xend(); ++i )
|
|
||||||
{
|
|
||||||
- if ( (std::abs(m_coeff_data[j][i])<<2) >= u_threshold )
|
|
||||||
+ if ( (static_cast<int>(std::abs(m_coeff_data[j][i]))<<2) >= u_threshold )
|
|
||||||
can_skip = false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -355,7 +355,7 @@ CoeffType QuantChooser::BlockAbsMax( con
|
|
||||||
{
|
|
||||||
for (int i=node.Xp() ; i<node.Xp()+node.Xl(); ++i)
|
|
||||||
{
|
|
||||||
- val = std::max( val , std::abs(m_coeff_data[j][i]) );
|
|
||||||
+ val = std::max( val , static_cast<int>(std::abs(m_coeff_data[j][i])) );
|
|
||||||
}// i
|
|
||||||
}// j
|
|
||||||
|
|
@ -1,20 +1,3 @@
|
|||||||
-------------------------------------------------------------------
|
|
||||||
Mon May 24 13:25:36 UTC 2010 - davejplater@gmail.com
|
|
||||||
|
|
||||||
- Split off doc subpackage
|
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
|
||||||
Mon May 24 07:01:37 UTC 2010 - davejplater@gmail.com
|
|
||||||
|
|
||||||
- Added Provides: and Obsoletes: for packman libdirac-devel
|
|
||||||
- Included patch from dirac git to fix uninitialised memory read
|
|
||||||
that causes the encoder to crash when using non-overlapping blocks.
|
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
|
||||||
Sun May 9 08:49:10 UTC 2010 - davejplater@gmail.com
|
|
||||||
|
|
||||||
- Fixed factory build with patch from git dirac-1.0.2-gcc45.patch
|
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Fri Dec 18 22:46:01 CET 2009 - jengelh@medozas.de
|
Fri Dec 18 22:46:01 CET 2009 - jengelh@medozas.de
|
||||||
|
|
||||||
|
45
dirac.spec
45
dirac.spec
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package dirac (Version 1.0.2)
|
# spec file for package dirac (Version 1.0.2)
|
||||||
#
|
#
|
||||||
# Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -20,18 +20,16 @@
|
|||||||
|
|
||||||
Name: dirac
|
Name: dirac
|
||||||
Version: 1.0.2
|
Version: 1.0.2
|
||||||
Release: 5
|
Release: 3
|
||||||
Url: http://diracvideo.org/
|
Url: http://diracvideo.org/
|
||||||
Group: Productivity/Multimedia/Video/Editors and Convertors
|
Group: Productivity/Multimedia/Video/Editors and Convertors
|
||||||
License: MPL ..
|
License: MPL ..
|
||||||
Summary: The Dirac_Video Codec
|
Summary: Dirac Video Codec
|
||||||
Source: %{name}-%{version}.tar.bz2
|
Source: %{name}-%{version}.tar.bz2
|
||||||
Patch0: 0001-Fix-uninitialised-memory-read-that-causes-the-encode.patch
|
|
||||||
Patch1: %{name}-%{version}-gcc45.patch
|
|
||||||
BuildRequires: gcc-c++ libstdc++-devel
|
BuildRequires: gcc-c++ libstdc++-devel
|
||||||
BuildRequires: libcppunit-devel
|
BuildRequires: libcppunit-devel
|
||||||
%ifnarch ia64 s390 s390x %sparc
|
%ifnarch ia64 s390 s390x %sparc
|
||||||
BuildRequires: pkg-config valgrind-devel
|
BuildRequires: valgrind-devel
|
||||||
%endif
|
%endif
|
||||||
BuildRequires: doxygen fdupes graphviz-gd texlive-latex
|
BuildRequires: doxygen fdupes graphviz-gd texlive-latex
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||||
@ -167,11 +165,8 @@ Authors:
|
|||||||
License: MPL ..
|
License: MPL ..
|
||||||
Group: Development/Libraries/C and C++
|
Group: Development/Libraries/C and C++
|
||||||
Summary: Development Files for Dirac Video Codec
|
Summary: Development Files for Dirac Video Codec
|
||||||
AutoReqProv: on
|
|
||||||
Requires: libdirac_decoder0 = %{version}
|
Requires: libdirac_decoder0 = %{version}
|
||||||
Requires: libdirac_encoder0 = %{version}
|
Requires: libdirac_encoder0 = %{version}
|
||||||
Provides: libdirac-devel = %{version}-%{release}
|
|
||||||
Obsoletes: libdirac-devel < %{version}-%{release}
|
|
||||||
|
|
||||||
%description devel
|
%description devel
|
||||||
Dirac is an open source video codec. It uses a traditional hybrid video
|
Dirac is an open source video codec. It uses a traditional hybrid video
|
||||||
@ -212,22 +207,8 @@ Authors:
|
|||||||
Peter Bleackley <diracinfo@rd.bbc.co.uk>, BBC Research and Development
|
Peter Bleackley <diracinfo@rd.bbc.co.uk>, BBC Research and Development
|
||||||
Myo Tun <myo.tun@brunel.ac.uk>, Brunel University
|
Myo Tun <myo.tun@brunel.ac.uk>, Brunel University
|
||||||
|
|
||||||
%package doc
|
|
||||||
License: MPL ..
|
|
||||||
Group: Documentation/HTML
|
|
||||||
Summary: Dirac Video Codec api documentation
|
|
||||||
%if 0%{?suse_version} > 1110
|
|
||||||
BuildArch: noarch
|
|
||||||
%endif
|
|
||||||
|
|
||||||
%description doc
|
|
||||||
This package provides the api reference documentation for using dirac libraries
|
|
||||||
in your program.
|
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q
|
%setup -q
|
||||||
%patch0 -p1
|
|
||||||
%patch1 -p1
|
|
||||||
# Code is not mature enough for -Werror (unused results)
|
# Code is not mature enough for -Werror (unused results)
|
||||||
sed -i 's/-Werror//' configure.ac
|
sed -i 's/-Werror//' configure.ac
|
||||||
|
|
||||||
@ -241,10 +222,8 @@ export CXXFLAGS="$RPM_OPT_FLAGS -O0"
|
|||||||
%endif
|
%endif
|
||||||
%endif
|
%endif
|
||||||
%configure\
|
%configure\
|
||||||
--disable-static \
|
--disable-static
|
||||||
--docdir=%{_docdir}/packages/%{name}
|
%{__make} %{?jobs:-j%jobs} htmldir=%{_docdir}/%{name}/code/api_html
|
||||||
%{__make} %{?jobs:-j%jobs}
|
|
||||||
#htmldir=%{_docdir}/%{name}/code/api_html
|
|
||||||
|
|
||||||
%install
|
%install
|
||||||
%makeinstall htmldir=%{_docdir}/%{name}/code/api_html
|
%makeinstall htmldir=%{_docdir}/%{name}/code/api_html
|
||||||
@ -265,8 +244,8 @@ export CXXFLAGS="$RPM_OPT_FLAGS -O0"
|
|||||||
|
|
||||||
%files
|
%files
|
||||||
%defattr (-, root, root)
|
%defattr (-, root, root)
|
||||||
#%%doc AUTHORS COPYING ChangeLog NEWS README TODO
|
%doc %dir %{_docdir}/%{name}
|
||||||
#%%doc %{_docdir}/%{name}/[ACNRT]*
|
%doc %{_docdir}/%{name}/[ACNRT]*
|
||||||
%{_bindir}/*
|
%{_bindir}/*
|
||||||
|
|
||||||
%files -n libdirac_decoder0
|
%files -n libdirac_decoder0
|
||||||
@ -279,14 +258,10 @@ export CXXFLAGS="$RPM_OPT_FLAGS -O0"
|
|||||||
|
|
||||||
%files devel
|
%files devel
|
||||||
%defattr (-, root, root)
|
%defattr (-, root, root)
|
||||||
#%%doc %{_docdir}/%{name}/[ACNRT]*
|
%doc %{_docdir}/%{name}/code
|
||||||
%{_libdir}/*.so
|
%{_libdir}/*.so
|
||||||
#%{_libdir}/*.*a
|
#%{_libdir}/*.*a
|
||||||
%{_libdir}/pkgconfig/*.pc
|
%{_libdir}/pkgconfig/*.pc
|
||||||
%{_includedir}/%{name}
|
%{_includedir}/dirac
|
||||||
|
|
||||||
%files doc
|
|
||||||
%defattr (-, root, root)
|
|
||||||
%doc %{_docdir}/%{name}
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
Loading…
x
Reference in New Issue
Block a user