Author: thl
Update of /cvs/free/rpms/transcode/F-8
In directory se02.es.rpmfusion.net:/tmp/cvs-serv29470
Modified Files:
.cvsignore sources transcode.spec
Added Files:
transcode-1.0.5-ImageMagick.patch
transcode-1.0.5-dvdread.patch transcode-1.0.5-ffmpeg.patch
transcode-1.0.5-nuv.patch
Log Message:
initial import from livna
transcode-1.0.5-ImageMagick.patch:
--- NEW FILE transcode-1.0.5-ImageMagick.patch ---
diff -up transcode-1.0.5/configure.in.orig transcode-1.0.5/configure.in
--- transcode-1.0.5/configure.in.orig 2008-07-05 21:28:03.000000000 +0300
+++ transcode-1.0.5/configure.in 2008-07-05 21:30:32.000000000 +0300
@@ -1235,7 +1235,7 @@ dnl
IMAGEMAGICK_EXTRA_LIBS="$IMAGEMAGICK_EXTRA_LIBS -lz -lm"
dnl MagickWand libraries/headers always (?) are a superset of MagickCore ones.
TC_PKG_CHECK(imagemagick, no, IMAGEMAGICK, Wand-config, [magick/api.h],
- Magick, InitializeMagick, Wand, [
http://www.imagemagick.org/])
+ MagickWand, InitializeMagick, Wand, [
http://www.imagemagick.org/])
TC_PKG_HAVE(imagemagick, IMAGEMAGICK)
if test x"$have_imagemagick" = x"yes" ; then
AC_CHECK_HEADER([wand/magick-wand.h],
transcode-1.0.5-dvdread.patch:
--- NEW FILE transcode-1.0.5-dvdread.patch ---
diff -up transcode-1.0.5/configure.in.libdvdread transcode-1.0.5/configure.in
--- transcode-1.0.5/configure.in.libdvdread 2008-07-05 21:33:59.000000000 +0300
+++ transcode-1.0.5/configure.in 2008-07-05 21:34:00.000000000 +0300
@@ -947,7 +947,7 @@ if test x"$have_libdvdread" = x"yes" ; t
libdvdread_inc="no"
save_CPPFLAGS="$CPPFLAGS"
CPPFLAGS="$CPPFLAGS $libdvdread_ii"
- AC_CHECK_HEADER([dvdread/dvd_reader.h],
+ AC_CHECK_HEADER([libdvdread/dvd_reader.h],
[AC_DEFINE([HAVE_LIBDVDREAD_INC], [1],
[have libdvdread includes in separate path])
libdvdread_inc="yes"])
--- transcode-1.0.5/import/dvd_reader.c.libdvdread 2008-07-05 21:41:22.000000000 +0300
+++ transcode-1.0.5/import/dvd_reader.c 2008-07-05 21:41:37.000000000 +0300
@@ -31,11 +31,11 @@
#ifdef HAVE_LIBDVDREAD
#ifdef HAVE_LIBDVDREAD_INC
-#include <dvdread/dvd_reader.h>
-#include <dvdread/ifo_types.h>
-#include <dvdread/ifo_read.h>
-#include <dvdread/nav_read.h>
-#include <dvdread/nav_print.h>
+#include <libdvdread/dvd_reader.h>
+#include <libdvdread/ifo_types.h>
+#include <libdvdread/ifo_read.h>
+#include <libdvdread/nav_read.h>
+#include <libdvdread/nav_print.h>
#else
#include <dvd_reader.h>
#include <ifo_types.h>
diff -up transcode-1.0.5/import/iodump.c.libdvdread transcode-1.0.5/import/iodump.c
--- transcode-1.0.5/import/iodump.c.libdvdread 2008-07-05 21:43:27.000000000 +0300
+++ transcode-1.0.5/import/iodump.c 2008-07-05 21:43:52.000000000 +0300
@@ -31,7 +31,7 @@
#ifdef HAVE_LIBDVDREAD
#ifdef HAVE_LIBDVDREAD_INC
-#include <dvdread/dvd_reader.h>
+#include <libdvdread/dvd_reader.h>
#else
#include <dvd_reader.h>
#endif
transcode-1.0.5-ffmpeg.patch:
--- NEW FILE transcode-1.0.5-ffmpeg.patch ---
diff -up transcode-1.0.5/acinclude.m4.orig transcode-1.0.5/acinclude.m4
diff -up transcode-1.0.5/configure.in.orig transcode-1.0.5/configure.in
--- transcode-1.0.5/configure.in.orig 2008-07-03 20:02:33.000000000 +0300
+++ transcode-1.0.5/configure.in 2008-07-05 12:14:24.000000000 +0300
@@ -611,14 +611,14 @@ AC_ARG_ENABLE(libavcodec-static,
esac],
[enable_libavcodec_static=no])
LIBAVCODEC_EXTRA_LIBS="$LIBAVCODEC_EXTRA_LIBS $($PKG_CONFIG --libs
libavcodec)"
-TC_PKG_CHECK(libavcodec, required, LIBAVCODEC, no, [ffmpeg/avcodec.h],
- avcodec, avcodec_thread_init, FFMpeg, [
http://www.ffmpeg.org/])
+TC_PKG_CHECK(libavcodec, required, LIBAVCODEC, no, [ffmpeg/libavcodec/avcodec.h],
+ avcodec, avcodec_thread_init, libavcodec, [
http://www.ffmpeg.org/])
if test x"$have_libavcodec" = x"yes" ; then
save_CPPFLAGS="$CPPFLAGS"
CPPFLAGS="$CPPFLAGS $LIBAVCODEC_CFLAGS"
AC_TRY_RUN([
#include <stdio.h>
-#include <ffmpeg/avcodec.h>
+#include <libavcodec/avcodec.h>
int
main()
{
@@ -640,8 +640,8 @@ main()
],
[LIBAVCODEC_VERSION="`./conftest$ac_exeext | sed -ne
's,VER=\(.*\),\1,p'`"
LIBAVCODEC_BUILD="`./conftest$ac_exeext | sed -ne
's,BUILD=\(.*\),\1,p'`"],
- [TC_PKG_ERROR(libavcodec, ffmpeg/avcodec.h, required, libavcodec,
[
http://www.ffmpeg.org],
- [cannot compile ffmpeg/avcodec.h])],
+ [TC_PKG_ERROR(libavcodec, libavcodec/avcodec.h, required, libavcodec,
[
http://www.ffmpeg.org],
+ [cannot compile libavcodec/avcodec.h])],
[echo $ac_n "cross compiling; assumed OK... $ac_c"
LIBAVCODEC_VERSION=""
LIBAVCODEC_BUILD=""])
@@ -820,7 +820,7 @@ AM_CONDITIONAL(HAVE_IBP, test x"$have_ib
dnl
dnl libpostproc
dnl
-TC_PKG_CHECK(libpostproc, no, LIBPOSTPROC, no, postprocess.h,
+TC_PKG_CHECK(libpostproc, no, LIBPOSTPROC, no, libpostproc/postprocess.h,
postproc, pp_postprocess, libpostproc, [
http://www.ffmpeg.org/])
TC_PKG_HAVE(libpostproc, LIBPOSTPROC)
diff -up transcode-1.0.5/export/export_ffmpeg.c.orig
transcode-1.0.5/export/export_ffmpeg.c
--- transcode-1.0.5/export/export_ffmpeg.c.orig 2008-07-03 20:37:46.000000000 +0300
+++ transcode-1.0.5/export/export_ffmpeg.c 2008-07-03 20:38:05.000000000 +0300
@@ -36,7 +36,7 @@
#include "vid_aux.h"
// FIXME
#undef EMULATE_FAST_INT
-#include <ffmpeg/avcodec.h>
+#include <libavcodec/avcodec.h>
#if !defined(INFINITY) && defined(HUGE_VAL)
#define INFINITY HUGE_VAL
diff -up transcode-1.0.5/export/ffmpeg_cfg.h.orig transcode-1.0.5/export/ffmpeg_cfg.h
--- transcode-1.0.5/export/ffmpeg_cfg.h.orig 2008-07-03 20:37:00.000000000 +0300
+++ transcode-1.0.5/export/ffmpeg_cfg.h 2008-07-03 20:37:20.000000000 +0300
@@ -2,7 +2,7 @@
#define __FFMPEG_CFG_H
#include "libioaux/configs.h"
-#include <ffmpeg/avcodec.h>
+#include <libavcodec/avcodec.h>
//char *lavc_param_vcodec = "mpeg4";
//extern int lavc_param_vbitrate;
diff -up transcode-1.0.5/filter/filter_resample.c.orig
transcode-1.0.5/filter/filter_resample.c
--- transcode-1.0.5/filter/filter_resample.c.orig 2008-07-03 20:38:33.000000000 +0300
+++ transcode-1.0.5/filter/filter_resample.c 2008-07-03 20:38:50.000000000 +0300
@@ -30,7 +30,7 @@
#include "filter.h"
#include "optstr.h"
-#include <ffmpeg/avcodec.h>
+#include <libavcodec/avcodec.h>
static char * resample_buffer = NULL;
static int bytes_per_sample;
diff -up transcode-1.0.5/filter/pp/filter_pp.c.orig transcode-1.0.5/filter/pp/filter_pp.c
--- transcode-1.0.5/filter/pp/filter_pp.c.orig 2008-07-05 12:28:19.000000000 +0300
+++ transcode-1.0.5/filter/pp/filter_pp.c 2008-07-05 12:28:48.000000000 +0300
@@ -35,7 +35,7 @@
#include <ctype.h>
#include <inttypes.h>
-#include "postprocess.h"
+#include "libpostproc/postprocess.h"
static pp_mode_t *mode[MAX_FILTER];
static pp_context_t *context[MAX_FILTER];
diff -up transcode-1.0.5/import/decode_lavc.c.orig transcode-1.0.5/import/decode_lavc.c
--- transcode-1.0.5/import/decode_lavc.c.orig 2008-07-03 20:39:16.000000000 +0300
+++ transcode-1.0.5/import/decode_lavc.c 2008-07-03 20:39:44.000000000 +0300
@@ -31,7 +31,7 @@
#ifdef EMULATE_FAST_INT
#undef EMULATE_FAST_INT
#endif
-#include <ffmpeg/avcodec.h>
+#include <libavcodec/avcodec.h>
#include "yuv2rgb.h"
#define READ_BUFFER_SIZE (10*1024*1024)
diff -up transcode-1.0.5/import/import_ffmpeg.c.orig
transcode-1.0.5/import/import_ffmpeg.c
--- transcode-1.0.5/import/import_ffmpeg.c.orig 2008-07-03 20:40:05.000000000 +0300
+++ transcode-1.0.5/import/import_ffmpeg.c 2008-07-03 20:40:25.000000000 +0300
@@ -38,7 +38,7 @@ static int capability_flag = TC_CAP_YUV
// FIXME
#undef EMULATE_FAST_INT
-#include <ffmpeg/avcodec.h>
+#include <libavcodec/avcodec.h>
#include "libvo/yuv2rgb.h"
#include "avilib/avilib.h"
diff -up transcode-1.0.5/src/transcode.c.orig transcode-1.0.5/src/transcode.c
--- transcode-1.0.5/src/transcode.c.orig 2008-01-05 16:37:15.000000000 +0200
+++ transcode-1.0.5/src/transcode.c 2008-07-03 20:41:27.000000000 +0300
@@ -4609,7 +4609,7 @@ int main(int argc, char *argv[]) {
// unneeded object files from a .a file.
#if 0
-#include <ffmpeg/avcodec.h>
+#include <libavcodec/avcodec.h>
void dummy_avcodec(void) {
AVCodecContext *ctx = NULL;
diff -up transcode-1.0.5/export/aud_aux.c.orig transcode-1.0.5/export/aud_aux.c
--- transcode-1.0.5/export/aud_aux.c.orig 2008-07-05 23:14:48.000000000 +0300
+++ transcode-1.0.5/export/aud_aux.c 2008-07-05 23:15:33.000000000 +0300
@@ -31,7 +31,7 @@
#include <inttypes.h>
#include <assert.h>
-#include <ffmpeg/avcodec.h>
+#include <libavcodec/avcodec.h>
#include "aud_aux.h"
#include "ac3.h"
transcode-1.0.5-nuv.patch:
--- NEW FILE transcode-1.0.5-nuv.patch ---
diff -up transcode-1.0.5/import/nuv/RTjpegN.c.types transcode-1.0.5/import/nuv/RTjpegN.c
--- transcode-1.0.5/import/nuv/RTjpegN.c.types 2004-10-18 02:01:08.000000000 +0300
+++ transcode-1.0.5/import/nuv/RTjpegN.c 2008-01-13 19:21:45.000000000 +0200
@@ -51,7 +51,7 @@ static const unsigned char RTjpeg_ZZ[64]
62, 55,
63 };
-static const __u64 RTjpeg_aan_tab[64]={
+static const uint64_t RTjpeg_aan_tab[64]={
4294967296ULL, 5957222912ULL, 5611718144ULL, 5050464768ULL, 4294967296ULL, 3374581504ULL,
2324432128ULL, 1184891264ULL,
5957222912ULL, 8263040512ULL, 7783580160ULL, 7005009920ULL, 5957222912ULL, 4680582144ULL,
3224107520ULL, 1643641088ULL,
5611718144ULL, 7783580160ULL, 7331904512ULL, 6598688768ULL, 5611718144ULL, 4408998912ULL,
3036936960ULL, 1548224000ULL,
@@ -63,16 +63,16 @@ static const __u64 RTjpeg_aan_tab[64]={
};
#ifndef MMX
-static __s32 RTjpeg_ws[64+31];
+static int32_t RTjpeg_ws[64+31];
#endif
-__u8 RTjpeg_alldata[2*64+4*64+4*64+4*64+4*64+32];
+uint8_t RTjpeg_alldata[2*64+4*64+4*64+4*64+4*64+32];
-__s16 *block; // rh
-__s16 *RTjpeg_block;
-__s32 *RTjpeg_lqt;
-__s32 *RTjpeg_cqt;
-__u32 *RTjpeg_liqt;
-__u32 *RTjpeg_ciqt;
+int16_t *block; // rh
+int16_t *RTjpeg_block;
+int32_t *RTjpeg_lqt;
+int32_t *RTjpeg_cqt;
+uint32_t *RTjpeg_liqt;
+uint32_t *RTjpeg_ciqt;
unsigned char RTjpeg_lb8;
unsigned char RTjpeg_cb8;
@@ -80,14 +80,14 @@ int RTjpeg_width, RTjpeg_height;
int RTjpeg_Ywidth, RTjpeg_Cwidth;
int RTjpeg_Ysize, RTjpeg_Csize;
-__s16 *RTjpeg_old=NULL;
+int16_t *RTjpeg_old=NULL;
#ifdef MMX
mmx_t RTjpeg_lmask;
mmx_t RTjpeg_cmask;
#else
-__u16 RTjpeg_lmask;
-__u16 RTjpeg_cmask;
+uint16_t RTjpeg_lmask;
+uint16_t RTjpeg_cmask;
#endif
int RTjpeg_mtest=0;
@@ -130,10 +130,10 @@ static const unsigned char RTjpeg_chrom_
/* Block to Stream (encoding) */
/* */
-int RTjpeg_b2s(__s16 *data, __s8 *strm, __u8 bt8)
+int RTjpeg_b2s(int16_t *data, int8_t *strm, uint8_t bt8)
{
register int ci, co=1;
- register __s16 ZZvalue;
+ register int16_t ZZvalue;
register unsigned char bitten;
register unsigned char bitoff;
@@ -154,7 +154,7 @@ int RTjpeg_b2s(__s16 *data, __s8 *strm,
// first byte allways written
strm[0]=
- (__u8)(data[RTjpeg_ZZ[0]]>254) ?
254:((data[RTjpeg_ZZ[0]]<0)?0:data[RTjpeg_ZZ[0]]);
+ (uint8_t)(data[RTjpeg_ZZ[0]]>254) ?
254:((data[RTjpeg_ZZ[0]]<0)?0:data[RTjpeg_ZZ[0]]);
ci=63;
@@ -270,11 +270,11 @@ HIRNWEH:
if(ZZvalue>0)
{
- strm[co++]=(__s8)(ZZvalue>127)?127:ZZvalue;
+ strm[co++]=(int8_t)(ZZvalue>127)?127:ZZvalue;
}
else
{
- strm[co++]=(__s8)(ZZvalue<-128)?-128:ZZvalue;
+ strm[co++]=(int8_t)(ZZvalue<-128)?-128:ZZvalue;
}
}
@@ -300,7 +300,7 @@ fprintf(stdout, "\n\n");
/* Stream to Block (decoding) */
/* */
-int RTjpeg_s2b(__s16 *data, __s8 *strm, __u8 bt8, __u32 *qtbl)
+int RTjpeg_s2b(int16_t *data, int8_t *strm, uint8_t bt8, uint32_t *qtbl)
{
int ci;
register int co;
@@ -310,7 +310,7 @@ int RTjpeg_s2b(__s16 *data, __s8 *strm,
/* first byte always read */
i=RTjpeg_ZZ[0];
- data[i]=((__u8)strm[0])*qtbl[i];
+ data[i]=((uint8_t)strm[0])*qtbl[i];
/* we start at the behind */
@@ -445,10 +445,10 @@ fprintf(stdout, "\n\n");
#else
-int RTjpeg_b2s(__s16 *data, __s8 *strm, __u8 bt8)
+int RTjpeg_b2s(int16_t *data, int8_t *strm, uint8_t bt8)
{
register int ci, co=1, tmp;
- register __s16 ZZvalue;
+ register int16_t ZZvalue;
#ifdef SHOWBLOCK
@@ -460,7 +460,7 @@ int RTjpeg_b2s(__s16 *data, __s8 *strm,
#endif
- (__u8)strm[0]=(__u8)(data[RTjpeg_ZZ[0]]>254) ?
254:((data[RTjpeg_ZZ[0]]<0)?0:data[RTjpeg_ZZ[0]]);
+ (uint8_t)strm[0]=(uint8_t)(data[RTjpeg_ZZ[0]]>254) ?
254:((data[RTjpeg_ZZ[0]]<0)?0:data[RTjpeg_ZZ[0]]);
for(ci=1; ci<=bt8; ci++)
{
@@ -468,11 +468,11 @@ int RTjpeg_b2s(__s16 *data, __s8 *strm,
if(ZZvalue>0)
{
- strm[co++]=(__s8)(ZZvalue>127)?127:ZZvalue;
+ strm[co++]=(int8_t)(ZZvalue>127)?127:ZZvalue;
}
else
{
- strm[co++]=(__s8)(ZZvalue<-128)?-128:ZZvalue;
+ strm[co++]=(int8_t)(ZZvalue<-128)?-128:ZZvalue;
}
}
@@ -482,11 +482,11 @@ int RTjpeg_b2s(__s16 *data, __s8 *strm,
if(ZZvalue>0)
{
- strm[co++]=(__s8)(ZZvalue>63)?63:ZZvalue;
+ strm[co++]=(int8_t)(ZZvalue>63)?63:ZZvalue;
}
else if(ZZvalue<0)
{
- strm[co++]=(__s8)(ZZvalue<-64)?-64:ZZvalue;
+ strm[co++]=(int8_t)(ZZvalue<-64)?-64:ZZvalue;
}
else /* compress zeros */
{
@@ -497,20 +497,20 @@ int RTjpeg_b2s(__s16 *data, __s8 *strm,
}
while((ci<64)&&(data[RTjpeg_ZZ[ci]]==0));
- strm[co++]=(__s8)(63+(ci-tmp));
+ strm[co++]=(int8_t)(63+(ci-tmp));
ci--;
}
}
return (int)co;
}
-int RTjpeg_s2b(__s16 *data, __s8 *strm, __u8 bt8, __u32 *qtbl)
+int RTjpeg_s2b(int16_t *data, int8_t *strm, uint8_t bt8, uint32_t *qtbl)
{
int ci=1, co=1, tmp;
register int i;
i=RTjpeg_ZZ[0];
- data[i]=((__u8)strm[0])*qtbl[i];
+ data[i]=((uint8_t)strm[0])*qtbl[i];
for(co=1; co<=bt8; co++)
{
@@ -540,19 +540,19 @@ int RTjpeg_s2b(__s16 *data, __s8 *strm,
void RTjpeg_quant_init(void)
{
int i;
- __s16 *qtbl;
+ int16_t *qtbl;
- qtbl=(__s16 *)RTjpeg_lqt;
- for(i=0; i<64; i++)qtbl[i]=(__s16)RTjpeg_lqt[i];
+ qtbl=(int16_t *)RTjpeg_lqt;
+ for(i=0; i<64; i++)qtbl[i]=(int16_t)RTjpeg_lqt[i];
- qtbl=(__s16 *)RTjpeg_cqt;
- for(i=0; i<64; i++)qtbl[i]=(__s16)RTjpeg_cqt[i];
+ qtbl=(int16_t *)RTjpeg_cqt;
+ for(i=0; i<64; i++)qtbl[i]=(int16_t)RTjpeg_cqt[i];
}
static mmx_t RTjpeg_ones=(mmx_t)(long long)0x0001000100010001LL;
static mmx_t RTjpeg_half=(mmx_t)(long long)0x7fff7fff7fff7fffLL;
-void RTjpeg_quant(__s16 *block, __s32 *qtbl)
+void RTjpeg_quant(int16_t *block, int32_t *qtbl)
{
int i;
mmx_t *bl, *ql;
@@ -593,12 +593,12 @@ void RTjpeg_quant_init(void)
{
}
-void RTjpeg_quant(__s16 *block, __s32 *qtbl)
+void RTjpeg_quant(int16_t *block, int32_t *qtbl)
{
int i;
for(i=0; i<64; i++)
- block[i]=(__s16)((block[i]*qtbl[i]+32767)>>16);
+ block[i]=(int16_t)((block[i]*qtbl[i]+32767)>>16);
}
#endif
@@ -614,14 +614,14 @@ static mmx_t RTjpeg_zero =(mmx_t)(long l
#else
-#define FIX_0_382683433 ((__s32) 98) /* FIX(0.382683433) */
-#define FIX_0_541196100 ((__s32) 139) /* FIX(0.541196100) */
-#define FIX_0_707106781 ((__s32) 181) /* FIX(0.707106781) */
-#define FIX_1_306562965 ((__s32) 334) /* FIX(1.306562965) */
-
-#define DESCALE10(x) (__s16)( ((x)+128) >> 8)
-#define DESCALE20(x) (__s16)(((x)+32768) >> 16)
-#define D_MULTIPLY(var,const) ((__s32) ((var) * (const)))
+#define FIX_0_382683433 ((int32_t) 98) /* FIX(0.382683433) */
+#define FIX_0_541196100 ((int32_t) 139) /* FIX(0.541196100) */
+#define FIX_0_707106781 ((int32_t) 181) /* FIX(0.707106781) */
+#define FIX_1_306562965 ((int32_t) 334) /* FIX(1.306562965) */
+
+#define DESCALE10(x) (int16_t)( ((x)+128) >> 8)
+#define DESCALE20(x) (int16_t)(((x)+32768) >> 16)
+#define D_MULTIPLY(var,const) ((int32_t) ((var) * (const)))
#endif
void RTjpeg_dct_init(void)
@@ -630,20 +630,20 @@ void RTjpeg_dct_init(void)
for(i=0; i<64; i++)
{
- RTjpeg_lqt[i]=(((__u64)RTjpeg_lqt[i]<<32)/RTjpeg_aan_tab[i]);
- RTjpeg_cqt[i]=(((__u64)RTjpeg_cqt[i]<<32)/RTjpeg_aan_tab[i]);
+ RTjpeg_lqt[i]=(((uint64_t)RTjpeg_lqt[i]<<32)/RTjpeg_aan_tab[i]);
+ RTjpeg_cqt[i]=(((uint64_t)RTjpeg_cqt[i]<<32)/RTjpeg_aan_tab[i]);
}
}
-void RTjpeg_dctY(__u8 *idata, __s16 *odata, int rskip)
+void RTjpeg_dctY(uint8_t *idata, int16_t *odata, int rskip)
{
#ifndef MMX
- __s32 tmp0, tmp1, tmp2, tmp3, tmp4, tmp5, tmp6, tmp7;
- __s32 tmp10, tmp11, tmp12, tmp13;
- __s32 z1, z2, z3, z4, z5, z11, z13;
- __u8 *idataptr;
- __s16 *odataptr;
- __s32 *wsptr;
+ int32_t tmp0, tmp1, tmp2, tmp3, tmp4, tmp5, tmp6, tmp7;
+ int32_t tmp10, tmp11, tmp12, tmp13;
+ int32_t z1, z2, z3, z4, z5, z11, z13;
+ uint8_t *idataptr;
+ int16_t *odataptr;
+ int32_t *wsptr;
int ctr;
idataptr = idata;
@@ -1540,17 +1540,17 @@ void RTjpeg_dctY(__u8 *idata, __s16 *oda
#endif
}
-#define FIX_1_082392200 ((__s32) 277) /* FIX(1.082392200) */
-#define FIX_1_414213562 ((__s32) 362) /* FIX(1.414213562) */
-#define FIX_1_847759065 ((__s32) 473) /* FIX(1.847759065) */
-#define FIX_2_613125930 ((__s32) 669) /* FIX(2.613125930) */
+#define FIX_1_082392200 ((int32_t) 277) /* FIX(1.082392200) */
+#define FIX_1_414213562 ((int32_t) 362) /* FIX(1.414213562) */
+#define FIX_1_847759065 ((int32_t) 473) /* FIX(1.847759065) */
+#define FIX_2_613125930 ((int32_t) 669) /* FIX(2.613125930) */
-#define DESCALE(x) (__s16)( ((x)+4) >> 3)
+#define DESCALE(x) (int16_t)( ((x)+4) >> 3)
/* clip yuv to 16..235 (should be 16..240 for cr/cb but ... */
#define RL(x) ((x)>235) ? 235 : (((x)<16) ? 16 : (x))
-#define MULTIPLY(var,const) (((__s32) ((var) * (const)) + 128)>>8)
+#define MULTIPLY(var,const) (((int32_t) ((var) * (const)) + 128)>>8)
void RTjpeg_idct_init(void)
{
@@ -1558,12 +1558,12 @@ void RTjpeg_idct_init(void)
for(i=0; i<64; i++)
{
- RTjpeg_liqt[i]=((__u64)RTjpeg_liqt[i]*RTjpeg_aan_tab[i])>>32;
- RTjpeg_ciqt[i]=((__u64)RTjpeg_ciqt[i]*RTjpeg_aan_tab[i])>>32;
+ RTjpeg_liqt[i]=((uint64_t)RTjpeg_liqt[i]*RTjpeg_aan_tab[i])>>32;
+ RTjpeg_ciqt[i]=((uint64_t)RTjpeg_ciqt[i]*RTjpeg_aan_tab[i])>>32;
}
}
-void RTjpeg_idct(__u8 *odata, __s16 *data, int rskip)
+void RTjpeg_idct(uint8_t *odata, int16_t *data, int rskip)
{
#ifdef MMX
@@ -2557,15 +2557,15 @@ static mmx_t fix_108n184 = (mmx_t)(long
movq_r2m(mm3, *(dataptr));
#else
- __s32 tmp0, tmp1, tmp2, tmp3, tmp4, tmp5, tmp6, tmp7;
- __s32 tmp10, tmp11, tmp12, tmp13;
- __s32 z5, z10, z11, z12, z13;
- __s16 *inptr;
- __s32 *wsptr;
- __u8 *outptr;
+ int32_t tmp0, tmp1, tmp2, tmp3, tmp4, tmp5, tmp6, tmp7;
+ int32_t tmp10, tmp11, tmp12, tmp13;
+ int32_t z5, z10, z11, z12, z13;
+ int16_t *inptr;
+ int32_t *wsptr;
+ uint8_t *outptr;
int ctr;
- __s32 dcval;
- __s32 workspace[64];
+ int32_t dcval;
+ int32_t workspace[64];
inptr = data;
wsptr = workspace;
@@ -2625,14 +2625,14 @@ static mmx_t fix_108n184 = (mmx_t)(long
tmp5 = tmp11 - tmp6;
tmp4 = tmp10 + tmp5;
- wsptr[0] = (__s32) (tmp0 + tmp7);
- wsptr[56] = (__s32) (tmp0 - tmp7);
- wsptr[8] = (__s32) (tmp1 + tmp6);
- wsptr[48] = (__s32) (tmp1 - tmp6);
- wsptr[16] = (__s32) (tmp2 + tmp5);
- wsptr[40] = (__s32) (tmp2 - tmp5);
- wsptr[32] = (__s32) (tmp3 + tmp4);
- wsptr[24] = (__s32) (tmp3 - tmp4);
+ wsptr[0] = (int32_t) (tmp0 + tmp7);
+ wsptr[56] = (int32_t) (tmp0 - tmp7);
+ wsptr[8] = (int32_t) (tmp1 + tmp6);
+ wsptr[48] = (int32_t) (tmp1 - tmp6);
+ wsptr[16] = (int32_t) (tmp2 + tmp5);
+ wsptr[40] = (int32_t) (tmp2 - tmp5);
+ wsptr[32] = (int32_t) (tmp3 + tmp4);
+ wsptr[24] = (int32_t) (tmp3 - tmp4);
inptr++;
wsptr++;
@@ -2709,15 +2709,15 @@ void RTjpeg_init_data(void)
dptr=dptr>>5;
dptr=dptr<<5; /* cache align data */
- RTjpeg_block=(__s16 *)dptr;
- dptr+=sizeof(__s16)*64;
- RTjpeg_lqt=(__s32 *)dptr;
- dptr+=sizeof(__s32)*64;
- RTjpeg_cqt=(__s32 *)dptr;
- dptr+=sizeof(__s32)*64;
- RTjpeg_liqt=(__u32 *)dptr;
- dptr+=sizeof(__u32)*64;
- RTjpeg_ciqt=(__u32 *)dptr;
+ RTjpeg_block=(int16_t *)dptr;
+ dptr+=sizeof(int16_t)*64;
+ RTjpeg_lqt=(int32_t *)dptr;
+ dptr+=sizeof(int32_t)*64;
+ RTjpeg_cqt=(int32_t *)dptr;
+ dptr+=sizeof(int32_t)*64;
+ RTjpeg_liqt=(uint32_t *)dptr;
+ dptr+=sizeof(uint32_t)*64;
+ RTjpeg_ciqt=(uint32_t *)dptr;
}
/*
@@ -2731,18 +2731,18 @@ Input: buf -> pointer to 128 ints for qu
Q -> quality factor (192=best, 32=worst)
*/
-void RTjpeg_init_Q(__u8 Q)
+void RTjpeg_init_Q(uint8_t Q)
{
int i;
- __u64 qual;
+ uint64_t qual;
- qual=(__u64)Q<<(32-7); /* 32 bit FP, 255=2, 0=0 */
+ qual=(uint64_t)Q<<(32-7); /* 32 bit FP, 255=2, 0=0 */
for(i=0; i<64; i++)
{
- RTjpeg_lqt[i]=(__s32)((qual/((__u64)RTjpeg_lum_quant_tbl[i]<<16))>>3);
+
RTjpeg_lqt[i]=(int32_t)((qual/((uint64_t)RTjpeg_lum_quant_tbl[i]<<16))>>3);
if(RTjpeg_lqt[i]==0)RTjpeg_lqt[i]=1;
- RTjpeg_cqt[i]=(__s32)((qual/((__u64)RTjpeg_chrom_quant_tbl[i]<<16))>>3);
+
RTjpeg_cqt[i]=(int32_t)((qual/((uint64_t)RTjpeg_chrom_quant_tbl[i]<<16))>>3);
if(RTjpeg_cqt[i]==0)RTjpeg_cqt[i]=1;
RTjpeg_liqt[i]=(1<<16)/(RTjpeg_lqt[i]<<3);
RTjpeg_ciqt[i]=(1<<16)/(RTjpeg_cqt[i]<<3);
@@ -2776,10 +2776,10 @@ Input: buf -> pointer to 128 ints for qu
*/
-void RTjpeg_init_compress(__u32 *buf, int width, int height, __u8 Q)
+void RTjpeg_init_compress(uint32_t *buf, int width, int height, uint8_t Q)
{
int i;
- __u64 qual;
+ uint64_t qual;
RTjpeg_init_data();
@@ -2790,13 +2790,13 @@ void RTjpeg_init_compress(__u32 *buf, in
RTjpeg_Cwidth = RTjpeg_width>>4;
RTjpeg_Csize= (width>>1) * height;
- qual=(__u64)Q<<(32-7); /* 32 bit FP, 255=2, 0=0 */
+ qual=(uint64_t)Q<<(32-7); /* 32 bit FP, 255=2, 0=0 */
for(i=0; i<64; i++)
{
- RTjpeg_lqt[i]=(__s32)((qual/((__u64)RTjpeg_lum_quant_tbl[i]<<16))>>3);
+
RTjpeg_lqt[i]=(int32_t)((qual/((uint64_t)RTjpeg_lum_quant_tbl[i]<<16))>>3);
if(RTjpeg_lqt[i]==0)RTjpeg_lqt[i]=1;
- RTjpeg_cqt[i]=(__s32)((qual/((__u64)RTjpeg_chrom_quant_tbl[i]<<16))>>3);
+
RTjpeg_cqt[i]=(int32_t)((qual/((uint64_t)RTjpeg_chrom_quant_tbl[i]<<16))>>3);
if(RTjpeg_cqt[i]==0)RTjpeg_cqt[i]=1;
RTjpeg_liqt[i]=(1<<16)/(RTjpeg_lqt[i]<<3);
RTjpeg_ciqt[i]=(1<<16)/(RTjpeg_cqt[i]<<3);
@@ -2820,7 +2820,7 @@ void RTjpeg_init_compress(__u32 *buf, in
buf[64+i]=RTjpeg_ciqt[i];
}
-void RTjpeg_init_decompress(__u32 *buf, int width, int height)
+void RTjpeg_init_decompress(uint32_t *buf, int width, int height)
{
int i;
@@ -2851,12 +2851,12 @@ void RTjpeg_init_decompress(__u32 *buf,
// RTjpeg_color_init();
}
-int RTjpeg_compressYUV420(__s8 *sp, unsigned char *bp)
+int RTjpeg_compressYUV420(int8_t *sp, unsigned char *bp)
{
- __s8 * sb;
- register __s8 * bp1 = bp + (RTjpeg_width<<3);
- register __s8 * bp2 = bp + RTjpeg_Ysize;
- register __s8 * bp3 = bp2 + (RTjpeg_Csize>>1);
+ int8_t * sb;
+ register int8_t * bp1 = bp + (RTjpeg_width<<3);
+ register int8_t * bp2 = bp + RTjpeg_Ysize;
+ register int8_t * bp3 = bp2 + (RTjpeg_Csize>>1);
register int i, j, k;
#ifdef MMX
@@ -2905,11 +2905,11 @@ int RTjpeg_compressYUV420(__s8 *sp, unsi
return (sp-sb);
}
-int RTjpeg_compressYUV422(__s8 *sp, unsigned char *bp)
+int RTjpeg_compressYUV422(int8_t *sp, unsigned char *bp)
{
- __s8 * sb;
- register __s8 * bp2 = bp + RTjpeg_Ysize;
- register __s8 * bp3 = bp2 + RTjpeg_Csize;
+ int8_t * sb;
+ register int8_t * bp2 = bp + RTjpeg_Ysize;
+ register int8_t * bp3 = bp2 + RTjpeg_Csize;
register int i, j, k;
#ifdef MMX
@@ -2949,9 +2949,9 @@ int RTjpeg_compressYUV422(__s8 *sp, unsi
return (sp-sb);
}
-int RTjpeg_compress8(__s8 *sp, unsigned char *bp)
+int RTjpeg_compress8(int8_t *sp, unsigned char *bp)
{
- __s8 * sb;
+ int8_t * sb;
int i, j;
#ifdef MMX
@@ -2977,10 +2977,10 @@ int RTjpeg_compress8(__s8 *sp, unsigned
return (sp-sb);
}
-void RTjpeg_decompressYUV422(__s8 *sp, __u8 *bp)
+void RTjpeg_decompressYUV422(int8_t *sp, uint8_t *bp)
{
- register __s8 * bp2 = bp + RTjpeg_Ysize;
- register __s8 * bp3 = bp2 + (RTjpeg_Csize);
+ register int8_t * bp2 = bp + RTjpeg_Ysize;
+ register int8_t * bp3 = bp2 + (RTjpeg_Csize);
int i, j,k;
#ifdef MMX
@@ -3025,11 +3025,11 @@ void RTjpeg_decompressYUV422(__s8 *sp, _
#endif
}
-void RTjpeg_decompressYUV420(__s8 *sp, __u8 *bp)
+void RTjpeg_decompressYUV420(int8_t *sp, uint8_t *bp)
{
- register __s8 * bp1 = bp + (RTjpeg_width<<3);
- register __s8 * bp2 = bp + RTjpeg_Ysize;
- register __s8 * bp3 = bp2 + (RTjpeg_Csize>>1);
+ register int8_t * bp1 = bp + (RTjpeg_width<<3);
+ register int8_t * bp2 = bp + RTjpeg_Ysize;
+ register int8_t * bp3 = bp2 + (RTjpeg_Csize>>1);
int i, j,k;
#ifdef MMX
@@ -3087,7 +3087,7 @@ void RTjpeg_decompressYUV420(__s8 *sp, _
#endif
}
-void RTjpeg_decompress8(__s8 *sp, __u8 *bp)
+void RTjpeg_decompress8(int8_t *sp, uint8_t *bp)
{
int i, j;
@@ -3126,7 +3126,7 @@ void RTjpeg_init_mcompress(void)
tmp=(unsigned long)RTjpeg_old;
tmp+=32;
tmp=tmp>>5;
- RTjpeg_old=(__s16 *)(tmp<<5);
+ RTjpeg_old=(int16_t *)(tmp<<5);
}
if (!RTjpeg_old)
{
@@ -3138,7 +3138,7 @@ void RTjpeg_init_mcompress(void)
#ifdef MMX
-int RTjpeg_bcomp(__s16 *old, mmx_t *mask)
+int RTjpeg_bcomp(int16_t *old, mmx_t *mask)
{
int i;
mmx_t *mold=(mmx_t *)old;
@@ -3176,7 +3176,7 @@ int RTjpeg_bcomp(__s16 *old, mmx_t *mask
if(result.q)
{
// if(!RTjpeg_mtest)
-// for(i=0; i<16; i++)((__u64 *)old)[i]=((__u64 *)RTjpeg_block)[i];
+// for(i=0; i<16; i++)((uint64_t *)old)[i]=((uint64_t *)RTjpeg_block)[i];
return 0;
}
// printf(".");
@@ -3184,7 +3184,7 @@ int RTjpeg_bcomp(__s16 *old, mmx_t *mask
}
#else
-int RTjpeg_bcomp(__s16 *old, __u16 *mask)
+int RTjpeg_bcomp(int16_t *old, uint16_t *mask)
{
int i;
@@ -3192,7 +3192,7 @@ int RTjpeg_bcomp(__s16 *old, __u16 *mask
if(abs(old[i]-RTjpeg_block[i])>*mask)
{
if(!RTjpeg_mtest)
- for(i=0; i<16; i++)((__u64 *)old)[i]=((__u64 *)RTjpeg_block)[i];
+ for(i=0; i<16; i++)((uint64_t *)old)[i]=((uint64_t *)RTjpeg_block)[i];
return 0;
}
return 1;
@@ -3204,19 +3204,19 @@ void RTjpeg_set_test(int i)
RTjpeg_mtest=i;
}
-int RTjpeg_mcompressYUV420(__s8 *sp, unsigned char *bp, __u16 lmask, __u16 cmask)
+int RTjpeg_mcompressYUV420(int8_t *sp, unsigned char *bp, uint16_t lmask, uint16_t
cmask)
{
- __s8 * sb;
-//rh __s16 *block;
- register __s8 * bp1 = bp + (RTjpeg_width<<3);
- register __s8 * bp2 = bp + RTjpeg_Ysize;
- register __s8 * bp3 = bp2 + (RTjpeg_Csize>>1);
+ int8_t * sb;
+//rh int16_t *block;
+ register int8_t * bp1 = bp + (RTjpeg_width<<3);
+ register int8_t * bp2 = bp + RTjpeg_Ysize;
+ register int8_t * bp3 = bp2 + (RTjpeg_Csize>>1);
register int i, j, k;
#ifdef MMX
emms();
-
RTjpeg_lmask=(mmx_t)(((__u64)lmask<<48)|((__u64)lmask<<32)|((__u64)lmask<<16)|lmask);
-
RTjpeg_cmask=(mmx_t)(((__u64)cmask<<48)|((__u64)cmask<<32)|((__u64)cmask<<16)|cmask);
+
RTjpeg_lmask=(mmx_t)(((uint64_t)lmask<<48)|((uint64_t)lmask<<32)|((uint64_t)lmask<<16)|lmask);
+
RTjpeg_cmask=(mmx_t)(((uint64_t)cmask<<48)|((uint64_t)cmask<<32)|((uint64_t)cmask<<16)|cmask);
#else
RTjpeg_lmask=lmask;
RTjpeg_cmask=cmask;
@@ -3233,7 +3233,7 @@ int RTjpeg_mcompressYUV420(__s8 *sp, uns
RTjpeg_quant(RTjpeg_block, RTjpeg_lqt);
if(RTjpeg_bcomp(block, &RTjpeg_lmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
}
else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_lb8);
block+=64;
@@ -3242,7 +3242,7 @@ int RTjpeg_mcompressYUV420(__s8 *sp, uns
RTjpeg_quant(RTjpeg_block, RTjpeg_lqt);
if(RTjpeg_bcomp(block, &RTjpeg_lmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
}
else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_lb8);
block+=64;
@@ -3251,7 +3251,7 @@ int RTjpeg_mcompressYUV420(__s8 *sp, uns
RTjpeg_quant(RTjpeg_block, RTjpeg_lqt);
if(RTjpeg_bcomp(block, &RTjpeg_lmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
}
else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_lb8);
block+=64;
@@ -3260,7 +3260,7 @@ int RTjpeg_mcompressYUV420(__s8 *sp, uns
RTjpeg_quant(RTjpeg_block, RTjpeg_lqt);
if(RTjpeg_bcomp(block, &RTjpeg_lmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
}
else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_lb8);
block+=64;
@@ -3269,7 +3269,7 @@ int RTjpeg_mcompressYUV420(__s8 *sp, uns
RTjpeg_quant(RTjpeg_block, RTjpeg_cqt);
if(RTjpeg_bcomp(block, &RTjpeg_cmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
}
else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_cb8);
block+=64;
@@ -3278,7 +3278,7 @@ int RTjpeg_mcompressYUV420(__s8 *sp, uns
RTjpeg_quant(RTjpeg_block, RTjpeg_cqt);
if(RTjpeg_bcomp(block, &RTjpeg_cmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
}
else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_cb8);
block+=64;
@@ -3296,18 +3296,18 @@ int RTjpeg_mcompressYUV420(__s8 *sp, uns
}
-int RTjpeg_mcompressYUV422(__s8 *sp, unsigned char *bp, __u16 lmask, __u16 cmask)
+int RTjpeg_mcompressYUV422(int8_t *sp, unsigned char *bp, uint16_t lmask, uint16_t
cmask)
{
- __s8 * sb;
- __s16 *block;
- register __s8 * bp2;
- register __s8 * bp3;
+ int8_t * sb;
+ int16_t *block;
+ register int8_t * bp2;
+ register int8_t * bp3;
register int i, j, k;
#ifdef MMX
emms();
-
RTjpeg_lmask=(mmx_t)(((__u64)lmask<<48)|((__u64)lmask<<32)|((__u64)lmask<<16)|lmask);
-
RTjpeg_cmask=(mmx_t)(((__u64)cmask<<48)|((__u64)cmask<<32)|((__u64)cmask<<16)|cmask);
+
RTjpeg_lmask=(mmx_t)(((uint64_t)lmask<<48)|((uint64_t)lmask<<32)|((uint64_t)lmask<<16)|lmask);
+
RTjpeg_cmask=(mmx_t)(((uint64_t)cmask<<48)|((uint64_t)cmask<<32)|((uint64_t)cmask<<16)|cmask);
#else
RTjpeg_lmask=lmask;
RTjpeg_cmask=cmask;
@@ -3328,7 +3328,7 @@ int RTjpeg_mcompressYUV422(__s8 *sp, uns
RTjpeg_quant(RTjpeg_block, RTjpeg_lqt);
if(RTjpeg_bcomp(block, &RTjpeg_lmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
}
else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_lb8);
block+=64;
@@ -3337,7 +3337,7 @@ int RTjpeg_mcompressYUV422(__s8 *sp, uns
RTjpeg_quant(RTjpeg_block, RTjpeg_lqt);
if(RTjpeg_bcomp(block, &RTjpeg_lmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
}
else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_lb8);
block+=64;
@@ -3346,7 +3346,7 @@ int RTjpeg_mcompressYUV422(__s8 *sp, uns
RTjpeg_quant(RTjpeg_block, RTjpeg_cqt);
if(RTjpeg_bcomp(block, &RTjpeg_cmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
}
else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_cb8);
block+=64;
@@ -3355,7 +3355,7 @@ int RTjpeg_mcompressYUV422(__s8 *sp, uns
RTjpeg_quant(RTjpeg_block, RTjpeg_cqt);
if(RTjpeg_bcomp(block, &RTjpeg_cmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
}
else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_cb8);
block+=64;
@@ -3372,15 +3372,15 @@ int RTjpeg_mcompressYUV422(__s8 *sp, uns
return (sp-sb);
}
-int RTjpeg_mcompress8(__s8 *sp, unsigned char *bp, __u16 lmask)
+int RTjpeg_mcompress8(int8_t *sp, unsigned char *bp, uint16_t lmask)
{
- __s8 * sb;
- __s16 *block;
+ int8_t * sb;
+ int16_t *block;
int i, j;
#ifdef MMX
emms();
-
RTjpeg_lmask=(mmx_t)(((__u64)lmask<<48)|((__u64)lmask<<32)|((__u64)lmask<<16)|lmask);
+
RTjpeg_lmask=(mmx_t)(((uint64_t)lmask<<48)|((uint64_t)lmask<<32)|((uint64_t)lmask<<16)|lmask);
#else
RTjpeg_lmask=lmask;
#endif
@@ -3397,7 +3397,7 @@ int RTjpeg_mcompress8(__s8 *sp, unsigned
RTjpeg_quant(RTjpeg_block, RTjpeg_lqt);
if(RTjpeg_bcomp(block, &RTjpeg_lmask))
{
- *((__u8 *)sp++)=255;
+ *((uint8_t *)sp++)=255;
// printf("* %d ", sp[-1]);
} else sp+=RTjpeg_b2s(RTjpeg_block, sp, RTjpeg_lb8);
block+=64;
@@ -3420,12 +3420,12 @@ void RTjpeg_color_init(void)
#define KcbB 132252
#define Ky 76284
-void RTjpeg_yuv422rgb(__u8 *buf, __u8 *rgb, int stride)
+void RTjpeg_yuv422rgb(uint8_t *buf, uint8_t *rgb, int stride)
{
int tmp;
int i, j;
- __s32 y, crR, crG, cbG, cbB;
- __u8 *bufcr, *bufcb, *bufy, *bufoute;
+ int32_t y, crR, crG, cbG, cbB;
+ uint8_t *bufcr, *bufcb, *bufy, *bufoute;
int yskip;
yskip=RTjpeg_width;
@@ -3468,12 +3468,12 @@ void RTjpeg_yuv422rgb(__u8 *buf, __u8 *r
}
-void RTjpeg_yuv420rgb(__u8 *buf, __u8 *rgb, int stride)
+void RTjpeg_yuv420rgb(uint8_t *buf, uint8_t *rgb, int stride)
{
int tmp;
int i, j;
- __s32 y, crR, crG, cbG, cbB;
- __u8 *bufcr, *bufcb, *bufy, *bufoute, *bufouto;
+ int32_t y, crR, crG, cbG, cbB;
+ uint8_t *bufcr, *bufcb, *bufy, *bufoute, *bufouto;
int oskip, yskip;
if(stride==0)
@@ -3542,12 +3542,12 @@ void RTjpeg_yuv420rgb(__u8 *buf, __u8 *r
}
-void RTjpeg_yuvrgb32(__u8 *buf, __u8 *rgb, int stride)
+void RTjpeg_yuvrgb32(uint8_t *buf, uint8_t *rgb, int stride)
{
int tmp;
int i, j;
- __s32 y, crR, crG, cbG, cbB;
- __u8 *bufcr, *bufcb, *bufy, *bufoute, *bufouto;
+ int32_t y, crR, crG, cbG, cbB;
+ uint8_t *bufcr, *bufcb, *bufy, *bufoute, *bufouto;
int oskip, yskip;
if(stride==0)
@@ -3618,12 +3618,12 @@ void RTjpeg_yuvrgb32(__u8 *buf, __u8 *rg
}
}
-void RTjpeg_yuvrgb24(__u8 *buf, __u8 *rgb, int stride)
+void RTjpeg_yuvrgb24(uint8_t *buf, uint8_t *rgb, int stride)
{
int tmp;
int i, j;
- __s32 y, crR, crG, cbG, cbB;
- __u8 *bufcr, *bufcb, *bufy, *bufoute, *bufouto;
+ int32_t y, crR, crG, cbG, cbB;
+ uint8_t *bufcr, *bufcb, *bufy, *bufoute, *bufouto;
int oskip, yskip;
if(stride==0)
@@ -3691,12 +3691,12 @@ void RTjpeg_yuvrgb24(__u8 *buf, __u8 *rg
}
}
-void RTjpeg_yuvrgb16(__u8 *buf, __u8 *rgb, int stride)
+void RTjpeg_yuvrgb16(uint8_t *buf, uint8_t *rgb, int stride)
{
int tmp;
int i, j;
- __s32 y, crR, crG, cbG, cbB;
- __u8 *bufcr, *bufcb, *bufy, *bufoute, *bufouto;
+ int32_t y, crR, crG, cbG, cbB;
+ uint8_t *bufcr, *bufcb, *bufy, *bufoute, *bufouto;
int oskip, yskip;
unsigned char r, g, b;
@@ -3788,7 +3788,7 @@ void RTjpeg_yuvrgb16(__u8 *buf, __u8 *rg
/* fix stride */
-void RTjpeg_yuvrgb8(__u8 *buf, __u8 *rgb, int stride)
+void RTjpeg_yuvrgb8(uint8_t *buf, uint8_t *rgb, int stride)
{
bcopy(buf, rgb, RTjpeg_width*RTjpeg_height);
}
diff -up transcode-1.0.5/import/nuv/RTjpegN.h.types transcode-1.0.5/import/nuv/RTjpegN.h
--- transcode-1.0.5/import/nuv/RTjpegN.h.types 2003-03-08 15:42:48.000000000 +0200
+++ transcode-1.0.5/import/nuv/RTjpegN.h 2008-01-13 19:26:18.000000000 +0200
@@ -22,37 +22,29 @@
*/
-#ifndef _I386_TYPES_H
-typedef unsigned char __u8;
-typedef unsigned short __u16;
-typedef unsigned long __u32;
-typedef unsigned long long __u64;
-typedef signed char __s8;
-typedef signed short __s16;
-typedef signed long __s32;
-#endif
+ #include <stdint.h>
-extern void RTjpeg_init_Q(__u8 Q);
-extern void RTjpeg_init_compress(long unsigned int *buf, int width, int height, __u8 Q);
-extern void RTjpeg_init_decompress(long unsigned int *buf, int width, int height);
-extern int RTjpeg_compressYUV420(__s8 *sp, unsigned char *bp);
-extern int RTjpeg_compressYUV422(__s8 *sp, unsigned char *bp);
-extern void RTjpeg_decompressYUV420(__s8 *sp, __u8 *bp);
-extern void RTjpeg_decompressYUV422(__s8 *sp, __u8 *bp);
-extern int RTjpeg_compress8(__s8 *sp, unsigned char *bp);
-extern void RTjpeg_decompress8(__s8 *sp, __u8 *bp);
+extern void RTjpeg_init_Q(uint8_t Q);
+extern void RTjpeg_init_compress(uint32_t *buf, int width, int height, uint8_t Q);
+extern void RTjpeg_init_decompress(uint32_t *buf, int width, int height);
+extern int RTjpeg_compressYUV420(int8_t *sp, unsigned char *bp);
+extern int RTjpeg_compressYUV422(int8_t *sp, unsigned char *bp);
+extern void RTjpeg_decompressYUV420(int8_t *sp, uint8_t *bp);
+extern void RTjpeg_decompressYUV422(int8_t *sp, uint8_t *bp);
+extern int RTjpeg_compress8(int8_t *sp, unsigned char *bp);
+extern void RTjpeg_decompress8(int8_t *sp, uint8_t *bp);
extern void RTjpeg_init_mcompress(void);
-extern int RTjpeg_mcompressYUV420(__s8 *sp, unsigned char *bp, __u16 lmask, __u16
cmask);
-extern int RTjpeg_mcompressYUV422(__s8 *sp, unsigned char *bp, __u16 lmask, __u16
cmask);
-extern int RTjpeg_mcompress8(__s8 *sp, unsigned char *bp, __u16 lmask);
+extern int RTjpeg_mcompressYUV420(int8_t *sp, unsigned char *bp, uint16_t lmask, uint16_t
cmask);
+extern int RTjpeg_mcompressYUV422(int8_t *sp, unsigned char *bp, uint16_t lmask, uint16_t
cmask);
+extern int RTjpeg_mcompress8(int8_t *sp, unsigned char *bp, uint16_t lmask);
extern void RTjpeg_set_test(int i);
-extern void RTjpeg_yuv420rgb(__u8 *buf, __u8 *rgb, int stride);
-extern void RTjpeg_yuv422rgb(__u8 *buf, __u8 *rgb, int stride);
-extern void RTjpeg_yuvrgb8(__u8 *buf, __u8 *rgb, int stride);
-extern void RTjpeg_yuvrgb16(__u8 *buf, __u8 *rgb, int stride);
-extern void RTjpeg_yuvrgb24(__u8 *buf, __u8 *rgb, int stride);
-extern void RTjpeg_yuvrgb32(__u8 *buf, __u8 *rgb, int stride);
+extern void RTjpeg_yuv420rgb(uint8_t *buf, uint8_t *rgb, int stride);
+extern void RTjpeg_yuv422rgb(uint8_t *buf, uint8_t *rgb, int stride);
+extern void RTjpeg_yuvrgb8(uint8_t *buf, uint8_t *rgb, int stride);
+extern void RTjpeg_yuvrgb16(uint8_t *buf, uint8_t *rgb, int stride);
+extern void RTjpeg_yuvrgb24(uint8_t *buf, uint8_t *rgb, int stride);
+extern void RTjpeg_yuvrgb32(uint8_t *buf, uint8_t *rgb, int stride);
diff -up transcode-1.0.5/import/nuv/rtjpeg_vid_plugin.c.types
transcode-1.0.5/import/nuv/rtjpeg_vid_plugin.c
--- transcode-1.0.5/import/nuv/rtjpeg_vid_plugin.c.types 2008-01-13 19:30:54.000000000
+0200
+++ transcode-1.0.5/import/nuv/rtjpeg_vid_plugin.c 2008-01-13 19:31:55.000000000 +0200
@@ -467,9 +467,9 @@ unsigned char *decode_vid_frame(struct r
// rtjpeg decompression
if (compoff) {
- RTjpeg_decompressYUV420((__s8 *)strm, rtjpeg_vid_buf);
+ RTjpeg_decompressYUV420((int8_t *)strm, rtjpeg_vid_buf);
} else {
- RTjpeg_decompressYUV420((__s8 *)buf2, rtjpeg_vid_buf);
+ RTjpeg_decompressYUV420((int8_t *)buf2, rtjpeg_vid_buf);
}
return(rtjpeg_vid_buf);
diff -up transcode-1.0.5/import/nuv/README.rtjpeg.types
transcode-1.0.5/import/nuv/README.rtjpeg
--- transcode-1.0.5/import/nuv/README.rtjpeg.types 2003-03-08 15:42:48.000000000 +0200
+++ transcode-1.0.5/import/nuv/README.rtjpeg 2008-01-13 18:59:23.000000000 +0200
@@ -82,7 +82,7 @@ RTjpeg Functions:
=================
(some functions may not yet be implemented for all module types)
-extern void RTjpeg_init_Q(__u8 Q);
+extern void RTjpeg_init_Q(uint8_t Q);
----------------------------------
Change the quality factor for future compressions/decompressions to Q.
Q=255 ==> IJG jpeg 75% (max)
@@ -90,7 +90,7 @@ Q=128 ==> IJG jpeg 50%
Q=32 (min usable)
Q=1 (abstract art)
-extern void RTjpeg_init_compress(__u32 *buf, int width, int height, __u8 Q);
+extern void RTjpeg_init_compress(uint32_t *buf, int width, int height, uint8_t Q);
----------------------------------------------------------------------------
Initialise the compressor.
*buf is a pointer to 128 ints. The de-quantizer values are stored in this
@@ -100,13 +100,13 @@ between versions (although it is probabl
height is the height of the Y component of the image.
Q is the quality factor (see above)
-extern void RTjpeg_init_decompress(__u32 *buf, int width, int height);
+extern void RTjpeg_init_decompress(uint32_t *buf, int width, int height);
----------------------------------------------------------------------
Initialise decompressor (and color convertor).
*buf is a pointer to the 128 ints produced by init_compress.
width and height, as before.
-extern int RTjpeg_compress(__s8 *sp, unsigned char *bp);
+extern int RTjpeg_compress(int8_t *sp, unsigned char *bp);
--------------------------------------------------------
Compress the image.
*sp is a pointer to the output data (for safety, this buffer should be as
@@ -114,7 +114,7 @@ Compress the image.
*bp is a pointer to the input data (YUV420P format).
RETURN: the number of bytes actually used for the output stream.
-extern void RTjpeg_decompress(__s8 *sp, __u8 *bp);
+extern void RTjpeg_decompress(int8_t *sp, uint8_t *bp);
--------------------------------------------------
Decompress the image.
as before (no RETURN).
@@ -123,7 +123,7 @@ extern void RTjpeg_init_mcompress(void);
----------------------------------------
Initialise interframe compression.
-extern int RTjpeg_mcompress(__s8 *sp, unsigned char *bp, __u16 lmask, __u16 cmask);
+extern int RTjpeg_mcompress(int8_t *sp, unsigned char *bp, uint16_t lmask, uint16_t
cmask);
-----------------------------------------------------------------------------------
Perform interframe compression.
*sp, *bp as for compress
@@ -141,32 +141,32 @@ copy of the reference image. This is us
test multiple compression factors for compressed block size. Remember to
call mcompress with test mode = 0 BEFORE transmitting an encoded block.)
-extern void RTjpeg_yuvrgb(__u8 *buf, __u8 *rgb);
+extern void RTjpeg_yuvrgb(uint8_t *buf, uint8_t *rgb);
------------------------------------------------
Convert decompressed YUV420P data to RGB data
*buf pointer to YUV420P data
*rgb pointer to RGB data
-extern void RTjpeg_yuvrgb32(__u8 *buf, __u8 *rgb);
+extern void RTjpeg_yuvrgb32(uint8_t *buf, uint8_t *rgb);
--------------------------------------------------
convert to RGB32 data (display order)
-extern void RTjpeg_yuvrgb24(__u8 *buf, __u8 *rgb);
+extern void RTjpeg_yuvrgb24(uint8_t *buf, uint8_t *rgb);
--------------------------------------------------
convert to RGB24 (display order)
-extern void RTjpeg_yuvrgb16(__u8 *buf, __u8 *rgb);
+extern void RTjpeg_yuvrgb16(uint8_t *buf, uint8_t *rgb);
--------------------------------------------------
convert to RGB 565
-extern void RTjpeg_yuvrgb8(__u8 *buf, __u8 *rgb);
+extern void RTjpeg_yuvrgb8(uint8_t *buf, uint8_t *rgb);
-------------------------------------------------
convert to grey-scale (grin)
-extern void RTjpeg_double32(__u32 *buf);
-extern void RTjpeg_double24(__u8 *buf);
-extern void RTjpeg_double16(__u16 *buf);
-extern void RTjpeg_double8(__u8 *buf);
+extern void RTjpeg_double32(uint32_t *buf);
+extern void RTjpeg_double24(uint8_t *buf);
+extern void RTjpeg_double16(uint16_t *buf);
+extern void RTjpeg_double8(uint8_t *buf);
--------------------------------------
convert the image pointed to by *buf to double size (size is determined by
with and height from init_decompress).
Index: .cvsignore
===================================================================
RCS file: /cvs/free/rpms/transcode/F-8/.cvsignore,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- .cvsignore 24 Jul 2008 12:45:33 -0000 1.2
+++ .cvsignore 9 Aug 2008 09:35:26 -0000 1.3
@@ -1 +1 @@
-transcode-1.0.4.tar.bz2
+transcode-1.0.5.tar.bz2
Index: sources
===================================================================
RCS file: /cvs/free/rpms/transcode/F-8/sources,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- sources 24 Jul 2008 12:45:33 -0000 1.2
+++ sources 9 Aug 2008 09:35:26 -0000 1.3
@@ -1 +1 @@
-6f05b9efb8d67540dd6dbb7b8db47504 transcode-1.0.4.tar.bz2
+124a6055d304fa2d8577d7380e2bcb0c transcode-1.0.5.tar.bz2
Index: transcode.spec
===================================================================
RCS file: /cvs/free/rpms/transcode/F-8/transcode.spec,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- transcode.spec 24 Jul 2008 12:45:33 -0000 1.1
+++ transcode.spec 9 Aug 2008 09:35:26 -0000 1.2
@@ -6,8 +6,8 @@
%define pvmdir %{_datadir}/pvm3
Name: transcode
-Version: 1.0.4
-Release: 5%{?dist}
+Version: 1.0.5
+Release: 4%{?dist}
Summary: Video stream processing tool
Group: Applications/Multimedia
@@ -17,13 +17,16 @@
Patch0: %{name}-pvmbin.patch
Patch2: %{name}-1.0.2-lzo2.patch
Patch3: transcode-1.0.4.external_dv.patch
-Patch4: transcode-1.0.4.dep-cleanup.patch
-Patch5: transcode-1.0.4-shared_libmpeg3.patch
+Patch6: transcode-1.0.5-nuv.patch
+Patch7: transcode-1.0.5-ffmpeg.patch
+Patch8: transcode-1.0.5-dvdread.patch
+Patch9: transcode-1.0.5-ImageMagick.patch
+
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: libogg-devel
BuildRequires: libvorbis-devel
-BuildRequires: libdvdread-devel
+BuildRequires: libdvdread-devel >= 4.1.3
BuildRequires: a52dec-devel
BuildRequires: libxml2-devel
BuildRequires: libjpeg-devel
@@ -34,7 +37,7 @@
BuildRequires: libquicktime-devel >= 0.9.8
BuildRequires: lame-devel >= 3.89
BuildRequires: SDL-devel >= 1.1.6
-BuildRequires: ffmpeg-devel >= 0.4.9
+BuildRequires: ffmpeg-devel >= 0.4.9-0.46.20080614
BuildRequires: mpeg2dec-devel >= 0.4.0-0.lvn.3.b
BuildRequires: pvm
BuildRequires: libtheora-devel
@@ -45,7 +48,7 @@
%ifarch %{ix86}
BuildRequires: nasm
%endif
-BuildRequires: ImageMagick-devel >= 5.4.3
+BuildRequires: ImageMagick-devel >= 6.4.0.10
BuildRequires: libmpeg3-devel
# libtool + autotools for patch2, autoreconf
@@ -71,9 +74,10 @@
%patch2 -p1 -b .lzo
%patch3 -p1 -b .external_dv
rm filter/preview/dv_types.h
-%patch4 -p1 -b .dep-cleanup
-%patch5 -p1 -b .shared-libmpeg3
-
+%patch6 -p1 -b .types
+%patch7 -p1 -b .ffmpeg
+%patch8 -p1 -b .libdvdread
+%patch9 -p1 -b .ImageMagick
%build
autoreconf # for patch2, and fixes standard rpaths on lib64 archs
@@ -89,7 +93,6 @@
--enable-v4l \
--enable-oss \
--enable-libpostproc \
- --with-libpostproc-includes=%{_includedir}/postproc \
--enable-freetype2 \
--enable-ogg \
--enable-vorbis \
@@ -131,6 +134,26 @@
%changelog
+* Thu Aug 07 2008 Thorsten Leemhuis <fedora [AT] leemhuis [DOT] info - 1.0.5-4
+- rebuild
+
+* Thu Jul 3 2008 <david(a)juran.se> - 1.0.5-3
+- updated for new ffmpeg directory layout
+- updated for new libdvdread directory layout
+- libMagick split in libMagicCore and libMagicWand
+
+* Thu Jan 10 2008 David Juran <david(a)juran.se> - 1.0.5-1
+- Upgrade to 1.0.5
+- exchanve nuv patch to the one from HEAD
+- drop dep-cleanup patch as it's no longer needed
+- drop shared-libmpeg3 patch as it's no longer needed
+
+* Sun Dec 9 2007 David Juran <david(a)juran.se> - 1.0.4-7
+- Fix build error in nuv import
+
+* Sun Dec 9 2007 David Juran <david(a)juran.se> - 1.0.4-6
+- Rebuild for new libdvdread
+
* Tue Oct 16 2007 David Juran <david(a)juran.se> - 1.0.4-5
- use shared libmpeg3
- use a52dec default decoder as recommended