Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 505196 | Differences between
and this patch

Collapse All | Expand All

(-)k9copy-2.3.8-Source.orig/CMakeLists.txt (-37 / +9 lines)
Lines 16-25 Link Here
16
INCLUDE(CheckIncludeFiles)
16
INCLUDE(CheckIncludeFiles)
17
INCLUDE(FindLibMpeg2)
17
INCLUDE(FindLibMpeg2)
18
INCLUDE(FindXine)
18
INCLUDE(FindXine)
19
INCLUDE(FindAvcodec)
20
INCLUDE(FindAvformat)
21
INCLUDE(FindFFmpegScale)
19
INCLUDE(FindFFmpegScale)
22
#INCLUDE(FindLibDvdread)
20
INCLUDE(FindLibDvdread)
21
22
INCLUDE(FindPkgConfig OPTIONAL)
23
pkg_check_modules(LIBAV REQUIRED libavformat libavcodec libavutil libswscale)
23
24
24
set (VERSION 2.3.8)
25
set (VERSION 2.3.8)
25
26
Lines 63-76 Link Here
63
  FIND_LIBRARY(LIBDL_LIBRARY NAMES "c" PATHS )
64
  FIND_LIBRARY(LIBDL_LIBRARY NAMES "c" PATHS )
64
  MESSAGE(STATUS "Found library libc: ${LIBDL_LIBRARY}")
65
  MESSAGE(STATUS "Found library libc: ${LIBDL_LIBRARY}")
65
ENDIF (LIBDL_LIBRARY)
66
ENDIF (LIBDL_LIBRARY)
66
#FINDLIBDVDREAD("dvdread/ifo_types.h" "dvdread")
67
FINDLIBDVDREAD("dvdread/ifo_types.h" "dvdread")
67
68
68
69
FINDAVFORMAT("avformat")
70
FINDAVCODEC("avcodec")
71
69
72
add_definitions( -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS)
70
add_definitions( -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS)
73
add_subdirectory( src/dvdnav)
74
add_subdirectory( src/core )
71
add_subdirectory( src/core )
75
add_subdirectory( src/mpeg2)
72
add_subdirectory( src/mpeg2)
76
add_subdirectory(src/vamps)
73
add_subdirectory(src/vamps)
Lines 85-91 Link Here
85
add_subdirectory(doc)
82
add_subdirectory(doc)
86
83
87
include_directories(
84
include_directories(
88
 ${CMAKE_CURRENT_SOURCE_DIR}/src/dvdnav
89
 ${CMAKE_CURRENT_SOURCE_DIR}/src/devices
85
 ${CMAKE_CURRENT_SOURCE_DIR}/src/devices
90
 ${CMAKE_CURRENT_SOURCE_DIR}/src/core
86
 ${CMAKE_CURRENT_SOURCE_DIR}/src/core
91
 ${CMAKE_CURRENT_SOURCE_DIR}/src/vamps
87
 ${CMAKE_CURRENT_SOURCE_DIR}/src/vamps
Lines 97-106 Link Here
97
 ${CMAKE_CURRENT_SOURCE_DIR}/src/import
93
 ${CMAKE_CURRENT_SOURCE_DIR}/src/import
98
 ${CMAKE_CURRENT_SOURCE_DIR}/src/player
94
 ${CMAKE_CURRENT_SOURCE_DIR}/src/player
99
 ${CMAKE_CURRENT_SOURCE_DIR}/src/subtitles
95
 ${CMAKE_CURRENT_SOURCE_DIR}/src/subtitles
100
 ${CMAKE_CURRENT_SOURCE_DIR}/src/dvdread
101
 ${CMAKE_CURRENT_SOURCE_DIR}/src/batch
96
 ${CMAKE_CURRENT_SOURCE_DIR}/src/batch
102
${KDE4_INCLUDES} ${QT_INCLUDES}
97
${KDE4_INCLUDES} ${QT_INCLUDES}
103
#${LIBDVDREAD_INCLUDE_DIR}/dvdread
98
${LIBDVDREAD_INCLUDE_DIR}/dvdread
99
${LIBDVDREAD_INCLUDE_DIR}/dvdnav
104
 ${AVCODEC_INCLUDE_DIR}
100
 ${AVCODEC_INCLUDE_DIR}
105
 ${AVFORMAT_INCLUDE_DIR}
101
 ${AVFORMAT_INCLUDE_DIR}
106
 ${FFMPEGSCALE_INCLUDE_DIR}
102
 ${FFMPEGSCALE_INCLUDE_DIR}
Lines 116-149 Link Here
116
   src/subtitles/k9subtitle2pgm.cpp
112
   src/subtitles/k9subtitle2pgm.cpp
117
)
113
)
118
114
119
set (libdvdnav_SRCS
120
   src/dvdnav/decoder.c
121
   src/dvdnav/dvdnav.c
122
   src/dvdnav/highlight.c
123
   src/dvdnav/navigation.c
124
   src/dvdnav/read_cache.c
125
   src/dvdnav/remap.c
126
   src/dvdnav/searching.c
127
   src/dvdnav/settings.c
128
   src/dvdnav/vm.c
129
   src/dvdnav/vmcmd.c
130
)
131
132
set (vamps_SRCS
115
set (vamps_SRCS
133
  src/vamps/k9fifo.cpp
116
  src/vamps/k9fifo.cpp
134
  src/vamps/k9requant.cpp
117
  src/vamps/k9requant.cpp
135
  src/vamps/k9vamps.cpp
118
  src/vamps/k9vamps.cpp
136
)
119
)
137
120
138
set (dvdread_SRCS
139
   src/dvdread/dvd_input.c
140
   src/dvdread/dvd_reader.c
141
   src/dvdread/dvd_udf.c
142
   src/dvdread/ifo_read.c
143
   src/dvdread/md5.c
144
   src/dvdread/nav_read.c
145
)
146
147
121
148
set (core_SRCS
122
set (core_SRCS
149
  src/core/k9dvd.cpp
123
  src/core/k9dvd.cpp
Lines 309-320 Link Here
309
)
283
)
310
284
311
set (k9copylib_SRCS
285
set (k9copylib_SRCS
312
   ${libdvdnav_SRCS}
313
   ${core_SRCS}
286
   ${core_SRCS}
314
   ${vamps_SRCS}
287
   ${vamps_SRCS}
315
   ${mpeg2_SRCS}
288
   ${mpeg2_SRCS}
316
   ${subtitles_SRCS}
289
   ${subtitles_SRCS}
317
   ${dvdread_SRCS}
318
   ${backup_SRCS}
290
   ${backup_SRCS}
319
)
291
)
320
292
Lines 341-347 Link Here
341
313
342
314
343
kde4_add_library(k9copylib STATIC ${k9copylib_SRCS})
315
kde4_add_library(k9copylib STATIC ${k9copylib_SRCS})
344
target_link_libraries(k9copylib ${KDE4_KDEUI_LIBS} ${KDE4_KDESU_LIBS} ${KDE4_KIO_LIBS} ${LIBMPEG2_LIBRARY} ${LIBMPEG2CONVERT_LIBRARY} ${LIBDL_LIBRARY})
316
target_link_libraries(k9copylib ${KDE4_KDEUI_LIBS} ${KDE4_KDESU_LIBS} ${KDE4_KIO_LIBS} ${LIBMPEG2_LIBRARY} ${LIBMPEG2CONVERT_LIBRARY} ${LIBDL_LIBRARY} ${LIBDVDREAD_LIBRARY} dvdnav)
345
317
346
kde4_add_ui_files(k9copy_SRCS )
318
kde4_add_ui_files(k9copy_SRCS )
347
319
Lines 351-357 Link Here
351
323
352
 MESSAGE(STATUS "Found library solid: ${KDE4_SOLID_LIBS}")
324
 MESSAGE(STATUS "Found library solid: ${KDE4_SOLID_LIBS}")
353
325
354
target_link_libraries(k9copy k9copylib ${KDE4_KDEUI_LIBS} ${PHONON_LIBRARY} ${KDE4_SOLID_LIBS})
326
target_link_libraries(k9copy k9copylib ${KDE4_KDEUI_LIBS} ${PHONON_LIBRARY} ${KDE4_SOLID_LIBS} ${LIBAV_LIBRARIES})
355
target_link_libraries(k9play k9copylib ${KDE4_KDEUI_LIBS}  )
327
target_link_libraries(k9play k9copylib ${KDE4_KDEUI_LIBS}  )
356
target_link_libraries(k9xineplayer ${KDE4_KDEUI_LIBS} ${XINE_LIBRARY} ${X11_X11_LIB} )
328
target_link_libraries(k9xineplayer ${KDE4_KDEUI_LIBS} ${XINE_LIBRARY} ${X11_X11_LIB} )
357
329
(-)k9copy-2.3.8-Source.orig/config.h (-1 / +1 lines)
Lines 72-78 Link Here
72
/* #undef ADM_CPU_X86_64 */
72
/* #undef ADM_CPU_X86_64 */
73
73
74
/* ffmpeg with swscale support */
74
/* ffmpeg with swscale support */
75
/* #undef HAVE_SWSCALE */
75
#define HAVE_SWSCALE
76
76
77
/* opengl extensions available */
77
/* opengl extensions available */
78
/* #undef HAVE_OPENGL */
78
/* #undef HAVE_OPENGL */
(-)k9copy-2.3.8-Source.orig/main.cpp (-1 / +4 lines)
Lines 18-24 Link Here
18
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
18
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
19
 ***************************************************************************/
19
 ***************************************************************************/
20
20
21
#include "src/dvdnav/common.h"
21
#include <ifo_types.h>
22
#include <ifo_read.h>
23
#include <nav_read.h>
24
#include <nav_types.h>
22
#include "k9copy.h"
25
#include "k9copy.h"
23
#include "k9common.h"
26
#include "k9common.h"
24
#include <kapplication.h>
27
#include <kapplication.h>
(-)k9copy-2.3.8-Source.orig/src/assistant/k9assistant.cpp (-1 / +4 lines)
Lines 23-29 Link Here
23
#include "k9dvd.h"
23
#include "k9dvd.h"
24
#include "k9cddrive.h"
24
#include "k9cddrive.h"
25
#include "k9execcopy.h"
25
#include "k9execcopy.h"
26
#include "dvdread.h"
26
#include <ifo_types.h>
27
#include <ifo_read.h>
28
#include <nav_read.h>
29
#include <nav_types.h>
27
#include "k9settings.h"
30
#include "k9settings.h"
28
#include "k9dvdtitle.h"
31
#include "k9dvdtitle.h"
29
k9Assistant *k9Assistant::createAssistant() {
32
k9Assistant *k9Assistant::createAssistant() {
(-)k9copy-2.3.8-Source.orig/src/backup/k9dvdbackup.cpp (-1 / +4 lines)
Lines 40-46 Link Here
40
#endif
40
#endif
41
41
42
#include "k9backupdlg.h"
42
#include "k9backupdlg.h"
43
#include "dvdread.h"
43
#include <ifo_types.h>
44
#include <ifo_read.h>
45
#include <nav_read.h>
46
#include <nav_types.h>
44
#include "k9script.h"
47
#include "k9script.h"
45
#include "k9tools.h"
48
#include "k9tools.h"
46
49
(-)k9copy-2.3.8-Source.orig/src/backup/k9mp4enc.cpp (-1 / +1 lines)
Lines 619-625 Link Here
619
        //      cmd << "-lavfopts" << "i_certify_that_my_video_stream_does_not_use_b_frames";
619
        //      cmd << "-lavfopts" << "i_certify_that_my_video_stream_does_not_use_b_frames";
620
    }
620
    }
621
    //synchronize audio
621
    //synchronize audio
622
    cmd << "-async" << "1" ;
622
    cmd << "-async" << "44100" ;
623
    cmd << "-y"  << KShell::quoteArg(path);
623
    cmd << "-y"  << KShell::quoteArg(path);
624
    cmd << slNewAudio;
624
    cmd << slNewAudio;
625
//    if (m_extractMkv) {
625
//    if (m_extractMkv) {
(-)k9copy-2.3.8-Source.orig/src/backup/k9script.cpp (-1 / +4 lines)
Lines 13-19 Link Here
13
#include "k9dvd.h"
13
#include "k9dvd.h"
14
#include "k9dvdtitle.h"
14
#include "k9dvdtitle.h"
15
#include "bswap.h"
15
#include "bswap.h"
16
#include "dvdread.h"
16
#include <ifo_types.h>
17
#include <ifo_read.h>
18
#include <nav_read.h>
19
#include <nav_types.h>
17
#include <stdlib.h>
20
#include <stdlib.h>
18
21
19
k9Script::k9Script(ifo_handle_t *_ifo, k9DVD *_dvd ) {
22
k9Script::k9Script(ifo_handle_t *_ifo, k9DVD *_dvd ) {
(-)k9copy-2.3.8-Source.orig/src/core/bswap.h (-1 / +1 lines)
Lines 35-41 Link Here
35
#include <sys/param.h>
35
#include <sys/param.h>
36
#endif
36
#endif
37
37
38
#if defined(__linux__)
38
#if defined(__GLIBC__)
39
#include <byteswap.h>
39
#include <byteswap.h>
40
#define B2N_16(x) x = bswap_16(x)
40
#define B2N_16(x) x = bswap_16(x)
41
#define B2N_32(x) x = bswap_32(x)
41
#define B2N_32(x) x = bswap_32(x)
(-)k9copy-2.3.8-Source.orig/src/core/k9audiocodecs.cpp (-4 / +4 lines)
Lines 75-84 Link Here
75
    m_codecs[4]=_k9AudioCodec("sonic","-oac lavc -lavcopts acodec=sonic:abitrate=$AUDBR","mencoder");
75
    m_codecs[4]=_k9AudioCodec("sonic","-oac lavc -lavcopts acodec=sonic:abitrate=$AUDBR","mencoder");
76
    m_codecs[5]=_k9AudioCodec("aac","-oac faac -faacopts br=$AUDBR","mencoder");
76
    m_codecs[5]=_k9AudioCodec("aac","-oac faac -faacopts br=$AUDBR","mencoder");
77
    m_codecs[6]=_k9AudioCodec("mp3 (lame)","-oac mp3lame -lameopts abr:br=$AUDBR","mencoder");
77
    m_codecs[6]=_k9AudioCodec("mp3 (lame)","-oac mp3lame -lameopts abr:br=$AUDBR","mencoder");
78
    m_codecs[7]=_k9AudioCodec("copy","-acodec copy","ffmpeg","");
78
    m_codecs[7]=_k9AudioCodec("copy","-codec:a copy","ffmpeg","");
79
    m_codecs[8]=_k9AudioCodec("mp3","-acodec libmp3lame -ab $AUDBRk -ac 2","ffmpeg",".mp3");
79
    m_codecs[8]=_k9AudioCodec("mp3","-codec:a libmp3lame -ab $AUDBRk -ac 2 -ar 44100","ffmpeg",".mp3");
80
    m_codecs[9]=_k9AudioCodec("vorbis","-acodec vorbis -ab $AUDBRk -ac 2","ffmpeg",".ogg");
80
    m_codecs[9]=_k9AudioCodec("vorbis","-codec:a vorbis -ab $AUDBRk -ac 2 -ar 44100","ffmpeg",".ogg");
81
    m_codecs[10]=_k9AudioCodec("aac","-acodec libfaac -ab $AUDBRk -ac 2","ffmpeg",".aac");
81
    m_codecs[10]=_k9AudioCodec("aac","-codec:a libfaac -ab $AUDBRk -ac 2 -ar 44100","ffmpeg",".aac");
82
82
83
    save();
83
    save();
84
}
84
}
(-)k9copy-2.3.8-Source.orig/src/core/k9dvdread.cpp (-1 / +4 lines)
Lines 10-16 Link Here
10
//
10
//
11
//
11
//
12
#include "k9dvdread.h"
12
#include "k9dvdread.h"
13
#include "dvdread.h"
13
#include <ifo_types.h>
14
#include <ifo_read.h>
15
#include <nav_read.h>
16
#include <nav_types.h>
14
#include "k9ifo2.h"
17
#include "k9ifo2.h"
15
18
16
k9DVDRead::k9DVDRead(){
19
k9DVDRead::k9DVDRead(){
(-)k9copy-2.3.8-Source.orig/src/core/k9ifo2.cpp (-1 / +4 lines)
Lines 19-25 Link Here
19
 ***************************************************************************/
19
 ***************************************************************************/
20
#include "k9ifo2.h"
20
#include "k9ifo2.h"
21
#include "bswap.h"
21
#include "bswap.h"
22
#include "dvdread.h"
22
#include <ifo_types.h>
23
#include <ifo_read.h>
24
#include <nav_read.h>
25
#include <nav_types.h>
23
#include <QDebug>
26
#include <QDebug>
24
27
25
k9Ifo2::k9Ifo2(k9DVDRead *_dvdread) {
28
k9Ifo2::k9Ifo2(k9DVDRead *_dvdread) {
(-)k9copy-2.3.8-Source.orig/src/core/k9videocodecs.cpp (-6 / +6 lines)
Lines 98-109 Link Here
98
      m_codecs[18]=_k9VideoCodec("ASUS v1","","-ovc lavc -lavcopts vcodec=asv1:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=asv1:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=asv1:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","mencoder");
98
      m_codecs[18]=_k9VideoCodec("ASUS v1","","-ovc lavc -lavcopts vcodec=asv1:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=asv1:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=asv1:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","mencoder");
99
      m_codecs[19]=_k9VideoCodec("ASUS v2","","-ovc lavc -lavcopts vcodec=asv2:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=asv2:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=asv2:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","mencoder");
99
      m_codecs[19]=_k9VideoCodec("ASUS v2","","-ovc lavc -lavcopts vcodec=asv2:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=asv2:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=asv2:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","mencoder");
100
      m_codecs[20]=_k9VideoCodec("flv","","-ovc lavc -lavcopts vcodec=flv:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=flv:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=flv:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","mencoder");
100
      m_codecs[20]=_k9VideoCodec("flv","","-ovc lavc -lavcopts vcodec=flv:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=flv:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","-ovc lavc -lavcopts vcodec=flv:vhq:v4mv:vqmin=2:vbitrate=$VIDBR:aspect=$ASPECT:turbo:vpass=$PASS -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP,scale=$WIDTH:$HEIGHT,dsize=$ASPECT","mencoder");
101
      m_codecs[21]=_k9VideoCodec("copy","","-vcodec copy","-vcodec copy","-vcodec copy","ffmpeg");
101
      m_codecs[21]=_k9VideoCodec("copy","","-codec:v copy","-codec:v copy","-codec:v copy","ffmpeg");
102
      m_codecs[22]=_k9VideoCodec("x264","","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP -aspect $ASPECT -vcodec libx264 -level 30","-b $VIDBRk -s $WIDTHx$HEIGHT -croptop $CROPTOP -cropbottom $CROPBOTTOM -cropleft $CROPLEFT -cropright $CROPRIGHT -aspect $ASPECT -vcodec libx264 -pass $PASS -passlogfile $PASSLOGFILE -level 30","-b $VIDBRk -s $WIDTHx$HEIGHT -croptop $CROPTOP -cropbottom $CROPBOTTOM -cropleft $CROPLEFT -cropright $CROPRIGHT -aspect $ASPECT -vcodec libx264 -pass $PASS -passlogfile $PASSLOGFILE -level 30","ffmpeg");
102
      m_codecs[22]=_k9VideoCodec("x264","","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v libx264 -level 30","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$WIDTH-$CROPRIGHT-$CROPLEFT:$HEIGHT-$CROPTOP-$CROPBOTTOM:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v libx264 -pass $PASS -passlogfile $PASSLOGFILE -level 30","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$WIDTH-$CROPRIGHT-$CROPLEFT:$HEIGHT-$CROPTOP-$CROPBOTTOM:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v libx264 -pass $PASS -passlogfile $PASSLOGFILE -level 30","ffmpeg");
103
      m_codecs[23]=_k9VideoCodec("x264 (high)","","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP -aspect $ASPECT -vcodec libx264 -level 30 -flags +loop+mv4 -cmp 256 -partitions +parti4x4+parti8x8+partp4x4+partp8x8+partb8x8 -me_method hex -subq 7 -trellis 1 -refs 5 -bf 3 -flags2 +bpyramid+wpred+mixed_refs+dct8x8 -coder 1 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -qmin 10 -qmax 51 -qdiff 4","-b $VIDBRk -s $WIDTHx$HEIGHT -croptop $CROPTOP -cropbottom $CROPBOTTOM -cropleft $CROPLEFT -cropright $CROPRIGHT -aspect $ASPECT -vcodec libx264 -level 30 -flags +loop+mv4 -cmp 256 -partitions +parti4x4+parti8x8+partp4x4+partp8x8+partb8x8 -me_method hex -subq 7 -trellis 1 -refs 5 -bf 3 -flags2 +bpyramid+wpred+mixed_refs+dct8x8 -coder 1 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -qmin 10 -qmax 51 -qdiff 4 -pass $PASS -passlogfile $PASSLOGFILE","-b $VIDBRk -s $WIDTHx$HEIGHT -croptop $CROPTOP -cropbottom $CROPBOTTOM -cropleft $CROPLEFT -cropright $CROPRIGHT -aspect $ASPECT -vcodec libx264 -level 30 -flags +loop+mv4 -cmp 256 -partitions +parti4x4+parti8x8+partp4x4+partp8x8+partb8x8 -me_method hex -subq 7 -trellis 1 -refs 5 -bf 3 -flags2 +bpyramid+wpred+mixed_refs+dct8x8 -coder 1 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -qmin 10 -qmax 51 -qdiff 4 -pass $PASS -passlogfile $PASSLOGFILE","ffmpeg");
103
      m_codecs[23]=_k9VideoCodec("x264 (high)","","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v libx264 -level 30 -flags +loop+mv4 -cmp 256 -partitions +parti4x4+parti8x8+partp4x4+partp8x8+partb8x8 -me_method hex -subq 7 -trellis 1 -refs 5 -bf 3 -b-pyramid normal -weightb 1 -mixed-refs 1 -8x8dct 1 -coder 1 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -qmin 10 -qmax 51 -qdiff 4","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$WIDTH-$CROPRIGHT-$CROPLEFT:$HEIGHT-$CROPTOP-$CROPBOTTOM:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v libx264 -level 30 -flags +loop+mv4 -cmp 256 -partitions +parti4x4+parti8x8+partp4x4+partp8x8+partb8x8 -me_method hex -subq 7 -trellis 1 -refs 5 -bf 3 -b-pyramid normal -weightb 1 -mixed-refs 1 -8x8dct 1 -coder 1 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -qmin 10 -qmax 51 -qdiff 4 -pass $PASS -passlogfile $PASSLOGFILE","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$WIDTH-$CROPRIGHT-$CROPLEFT:$HEIGHT-$CROPTOP-$CROPBOTTOM:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v libx264 -level 30 -flags +loop+mv4 -cmp 256 -partitions +parti4x4+parti8x8+partp4x4+partp8x8+partb8x8 -me_method hex -subq 7 -trellis 1 -refs 5 -bf 3 -b-pyramid normal -weightb 1 -mixed-refs 1 -8x8dct 1 -coder 1 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -qmin 10 -qmax 51 -qdiff 4 -pass $PASS -passlogfile $PASSLOGFILE","ffmpeg");
104
      m_codecs[24]=_k9VideoCodec("MPEG-4 ","","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP -aspect $ASPECT -vcodec mpeg4 ","-b $VIDBRk -s $WIDTHx$HEIGHT -croptop $CROPTOP -cropbottom $CROPBOTTOM -cropleft $CROPLEFT -cropright $CROPRIGHT -aspect $ASPECT -vcodec mpeg4  -pass $PASS -passlogfile $PASSLOGFILE","-b $VIDBRk -s $WIDTHx$HEIGHT -croptop $CROPTOP -cropbottom $CROPBOTTOM -cropleft $CROPLEFT -cropright $CROPRIGHT -aspect $ASPECT -vcodec mpeg4 -pass $PASS -passlogfile $PASSLOGFILE","ffmpeg");
104
      m_codecs[24]=_k9VideoCodec("MPEG-4 ","","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v mpeg4 ","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$WIDTH-$CROPRIGHT-$CROPLEFT:$HEIGHT-$CROPTOP-$CROPBOTTOM:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v mpeg4  -pass $PASS -passlogfile $PASSLOGFILE","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$WIDTH-$CROPRIGHT-$CROPLEFT:$HEIGHT-$CROPTOP-$CROPBOTTOM:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v mpeg4 -pass $PASS -passlogfile $PASSLOGFILE","ffmpeg");
105
      m_codecs[25]=_k9VideoCodec("Flash Video","","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP -aspect $ASPECT -vcodec flv ","-b $VIDBRk -s $WIDTHx$HEIGHT -croptop $CROPTOP -cropbottom $CROPBOTTOM -cropleft $CROPLEFT -cropright $CROPRIGHT -aspect $ASPECT -vcodec flv -pass $PASS -passlogfile $PASSLOGFILE","-b $VIDBRk -s $WIDTHx$HEIGHT -croptop $CROPTOP -cropbottom $CROPBOTTOM -cropleft $CROPLEFT -cropright $CROPRIGHT -aspect $ASPECT -vcodec flv -pass $PASS -passlogfile $PASSLOGFILE","ffmpeg");
105
      m_codecs[25]=_k9VideoCodec("Flash Video","","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v flv ","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$WIDTH-$CROPRIGHT-$CROPLEFT:$HEIGHT-$CROPTOP-$CROPBOTTOM:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v flv -pass $PASS -passlogfile $PASSLOGFILE","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$WIDTH-$CROPRIGHT-$CROPLEFT:$HEIGHT-$CROPTOP-$CROPBOTTOM:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v flv -pass $PASS -passlogfile $PASSLOGFILE","ffmpeg");
106
      m_codecs[26]=_k9VideoCodec("Windows Media 8","","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP -aspect $ASPECT -vcodec wmv2","-b $VIDBRk -s $WIDTHx$HEIGHT -croptop $CROPTOP -cropbottom $CROPBOTTOM -cropleft $CROPLEFT -cropright $CROPRIGHT -aspect $ASPECT -vcodec wmv2 -pass $PASS -passlogfile $PASSLOGFILE","-b $VIDBRk -s $WIDTHx$HEIGHT -croptop $CROPTOP -cropbottom $CROPBOTTOM -cropleft $CROPLEFT -cropright $CROPRIGHT -aspect $ASPECT -vcodec wmv2 -pass $PASS -passlogfile $PASSLOGFILE","ffmpeg");
106
      m_codecs[26]=_k9VideoCodec("Windows Media 8","","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$CROPWIDTH:$CROPHEIGHT:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v wmv2","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$WIDTH-$CROPRIGHT-$CROPLEFT:$HEIGHT-$CROPTOP-$CROPBOTTOM:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v wmv2 -pass $PASS -passlogfile $PASSLOGFILE","-b $VIDBRk -s $WIDTHx$HEIGHT -vf crop=$WIDTH-$CROPRIGHT-$CROPLEFT:$HEIGHT-$CROPTOP-$CROPBOTTOM:$CROPLEFT:$CROPTOP -aspect $ASPECT -codec:v wmv2 -pass $PASS -passlogfile $PASSLOGFILE","ffmpeg");
107
107
108
      save();
108
      save();
109
109
(-)k9copy-2.3.8-Source.orig/src/import/k9avidecode.cpp (-86 / +7 lines)
Lines 10-24 Link Here
10
//
10
//
11
//
11
//
12
#include "k9avidecode.h"
12
#include "k9avidecode.h"
13
#include <avcodec.h>
14
#include <qimage.h>
13
#include <qimage.h>
15
#include <dlfcn.h>
14
#include <dlfcn.h>
16
#include "k9common.h"
15
#include "k9common.h"
17
16
18
#ifdef HAVE_SWSCALE
17
#ifdef HAVE_SWSCALE
19
18
20
#include "swscale.h"
21
22
static int sws_flags = SWS_BICUBIC;
19
static int sws_flags = SWS_BICUBIC;
23
20
24
#endif
21
#endif
Lines 35-101 Link Here
35
32
36
k9AviDecode::k9AviDecode(QObject *parent, const char *)
33
k9AviDecode::k9AviDecode(QObject *parent, const char *)
37
        : QObject(parent) {
34
        : QObject(parent) {
38
    CodecHandle=0;
39
    FormatHandle=0;
40
    SwscaleHandle=0;
41
    glibref=0;
42
    if (glibref==0) {
43
        CodecHandle=dlopen("libavcodec.so",RTLD_LAZY ); //| RTLD_GLOBAL
44
        FormatHandle=dlopen("libavformat.so",RTLD_LAZY);
45
#ifdef HAVE_SWSCALE
46
        SwscaleHandle=dlopen("libswscale.so",RTLD_LAZY);
47
        if (SwscaleHandle==0)
48
            SwscaleHandle=dlopen("libswscale.so.2",RTLD_LAZY);
49
#endif
50
    }
51
    m_error="";
35
    m_error="";
52
    QStringList errs;
36
    QStringList errs;
53
    if (!CodecHandle) {
54
        errs << i18n("Cannot open the library %1").arg("libavcodec");
55
    }
56
    if (!FormatHandle ) {
57
        errs << i18n("Cannot open the library %1").arg("libavformat");
58
    }
59
#ifdef HAVE_SWSCALE
60
    if (!SwscaleHandle) {
61
        errs << i18n("Cannot open the library %1").arg("libswscale");
62
    }
63
#endif
64
65
    av_register_all = (av_register_all_t)dlsym(FormatHandle,"av_register_all");
66
    av_open_input_file = (av_open_input_file_t)dlsym(FormatHandle,"av_open_input_file");
67
    av_find_stream_info = (av_find_stream_info_t)dlsym(FormatHandle,"av_find_stream_info");
68
    avcodec_find_decoder =(avcodec_find_decoder_t) dlsym(CodecHandle,"avcodec_find_decoder");
69
    avcodec_open = (avcodec_open_t)dlsym(CodecHandle,"avcodec_open");
70
    avcodec_alloc_frame = (avcodec_alloc_frame_t)dlsym(CodecHandle,"avcodec_alloc_frame");
71
    avpicture_get_size = (avpicture_get_size_t)dlsym(CodecHandle,"avpicture_get_size");
72
    av_malloc = (av_malloc_t)dlsym(CodecHandle,"av_malloc");
73
    avpicture_fill = (avpicture_fill_t)dlsym(CodecHandle,"avpicture_fill");
74
    av_read_frame = (av_read_frame_t)dlsym(FormatHandle,"av_read_frame");
75
    avcodec_decode_video = (avcodec_decode_video_t)dlsym(CodecHandle,"avcodec_decode_video");
76
    if (avcodec_decode_video==0) avcodec_decode_video=(avcodec_decode_video_t)dlsym(CodecHandle,"avcodec_decode_video2");
77
#ifndef HAVE_SWSCALE
78
    img_convert = (img_convert_t)dlsym(CodecHandle,"img_convert");
79
//if img_convert is null (deprecated in ffmpeg), we need libswscale
80
    if (!img_convert)
81
      errs << i18n("Cannot open the library %1").arg("libswscale");
82
#endif
83
    av_free = (av_free_t)dlsym(CodecHandle,"av_free");
84
    av_free_packet = (av_free_packet_t)dlsym(CodecHandle,"av_free_packet");
85
    if (av_free_packet==0)
86
         av_free_packet=av_free_packet_internal;
87
    avcodec_close = (avcodec_close_t)dlsym(FormatHandle,"avcodec_close");
88
    av_close_input_file = (av_close_input_file_t)dlsym(FormatHandle,"av_close_input_file");
89
    av_seek_frame=(av_seek_frame_t)dlsym(FormatHandle,"av_seek_frame");
90
    av_rescale_q=(av_rescale_q_t)dlsym(FormatHandle,"av_rescale_q");
91
    avcodec_flush_buffers=(avcodec_flush_buffers_t)dlsym(CodecHandle,"avcodec_flush_buffers");
92
#ifdef HAVE_SWSCALE
93
    sws_freeContext= (sws_freeContext_t)dlsym(SwscaleHandle,"sws_freeContext");
94
    sws_getContext=(sws_getContext_t)dlsym(SwscaleHandle,"sws_getContext");
95
    sws_scale= (sws_scale_t)dlsym(SwscaleHandle,"sws_scale");
96
#endif
97
    av_gettime=(av_gettime_t)dlsym(FormatHandle,"av_gettime");
98
    
99
    if (errs.count() >0) {
37
    if (errs.count() >0) {
100
        m_error=errs.join("\n");
38
        m_error=errs.join("\n");
101
        k9Dialogs::error(m_error,"k9copy",QStringList());
39
        k9Dialogs::error(m_error,"k9copy",QStringList());
Lines 104-131 Link Here
104
    
42
    
105
    av_register_all();
43
    av_register_all();
106
    m_opened=false;
44
    m_opened=false;
107
108
    glibref++;
109
}
45
}
110
46
111
47
112
k9AviDecode::~k9AviDecode() {
48
k9AviDecode::~k9AviDecode() {
113
    if (m_opened)
49
    if (m_opened)
114
        close();
50
        close();
115
    glibref--;
116
    if (glibref==0) {
117
	if (FormatHandle)
118
        	dlclose(FormatHandle);
119
	if (CodecHandle)
120
        	dlclose(CodecHandle);
121
#ifdef HAVE_SWSCALE
122
	if (SwscaleHandle)
123
        	dlclose(CodecHandle);
124
#endif
125
	FormatHandle=0;
126
	CodecHandle=0;
127
    }
128
129
}
51
}
130
52
131
bool k9AviDecode::open(const QString & _fileName) {
53
bool k9AviDecode::open(const QString & _fileName) {
Lines 134-145 Link Here
134
        close();
56
        close();
135
57
136
    // Open video file
58
    // Open video file
137
    if (av_open_input_file(&m_FormatCtx, _fileName.toUtf8(), NULL, 0, NULL)!=0) {
59
    if (avformat_open_input(&m_FormatCtx, _fileName.toUtf8(), NULL, NULL)!=0) {
138
        m_error=i18n("Couldn't open the file %1").arg(_fileName);
60
        m_error=i18n("Couldn't open the file %1").arg(_fileName);
139
        return false; // Couldn't open file}
61
        return false; // Couldn't open file}
140
    }
62
    }
141
// Retrieve stream information
63
// Retrieve stream information
142
    if (av_find_stream_info(m_FormatCtx)<0) {
64
    if (avformat_find_stream_info(m_FormatCtx, NULL)<0) {
143
        m_error =i18n("Couldn't find stream information");
65
        m_error =i18n("Couldn't find stream information");
144
        return false; // Couldn't find stream information
66
        return false; // Couldn't find stream information
145
    }
67
    }
Lines 168-174 Link Here
168
        return false; // Codec not found
90
        return false; // Codec not found
169
    }
91
    }
170
// Open codec
92
// Open codec
171
    if (avcodec_open(m_CodecCtx, m_Codec)<0) {
93
    if (avcodec_open2(m_CodecCtx, m_Codec, NULL)<0) {
172
        m_error =i18n("Could'nt open the codec");
94
        m_error =i18n("Could'nt open the codec");
173
        return false; // Could not open codec
95
        return false; // Could not open codec
174
    }
96
    }
Lines 245-259 Link Here
245
        // Is this a packet from the video stream?
167
        // Is this a packet from the video stream?
246
        if (packet.stream_index==m_videoStream) {
168
        if (packet.stream_index==m_videoStream) {
247
            // Decode video frame
169
            // Decode video frame
248
            avcodec_decode_video(m_CodecCtx, m_Frame, &frameFinished,
170
            avcodec_decode_video2(m_CodecCtx, m_Frame, &frameFinished,
249
                                 packet.data, packet.size);
171
                                 &packet);
250
172
251
            // Did we get a video frame?
173
            // Did we get a video frame?
252
            if (frameFinished) {
174
            if (frameFinished) {
253
//            if (m_Frame->pts >=fspos)
175
//            if (m_Frame->pts >=fspos)
254
		int64_t cur_dts=fspos;
176
		int64_t cur_dts=fspos;
255
		if (m_FormatCtx->cur_st)
177
		cur_dts=packet.dts;
256
		    cur_dts=	m_FormatCtx->cur_st->cur_dts;
257
                if (cur_dts >=fspos) {
178
                if (cur_dts >=fspos) {
258
                    bFound=true;
179
                    bFound=true;
259
#ifndef HAVE_SWSCALE
180
#ifndef HAVE_SWSCALE
Lines 309-315 Link Here
309
        avcodec_close(m_CodecCtx);
230
        avcodec_close(m_CodecCtx);
310
231
311
        // Close the video file
232
        // Close the video file
312
        av_close_input_file(m_FormatCtx);
233
        avformat_close_input(&m_FormatCtx);
313
        m_opened=false;
234
        m_opened=false;
314
    }
235
    }
315
}
236
}
(-)k9copy-2.3.8-Source.orig/src/import/k9avidecode.h (-63 / +6 lines)
Lines 14-62 Link Here
14
14
15
#include "k9common.h"
15
#include "k9common.h"
16
#include <qobject.h>
16
#include <qobject.h>
17
#include <avformat.h>
17
extern "C" {
18
#include <libavformat/avformat.h>
19
}
18
#include <qimage.h>
20
#include <qimage.h>
19
#include <cstdlib>
21
#include <cstdlib>
20
#include <QObject>
22
#include <QObject>
21
#ifdef HAVE_SWSCALE
23
#ifdef HAVE_SWSCALE
22
#include <swscale.h>
24
extern "C" {
25
#include <libswscale/swscale.h>
26
}
23
#endif
27
#endif
24
/**
28
/**
25
	@author Jean-Michel PETIT <k9copy@free.fr>
29
	@author Jean-Michel PETIT <k9copy@free.fr>
26
*/
30
*/
27
31
28
32
29
//typedef dvd_file_t * (*DVDOpenFile_t) ( dvd_reader_t *, int, dvd_read_domain_t );
30
typedef void (*av_register_all_t) (void);
31
typedef int64_t (*av_gettime_t) (void);
32
typedef int (*av_open_input_file_t)(AVFormatContext **, const char *,AVInputFormat *,int, AVFormatParameters *);
33
typedef int (*av_find_stream_info_t)(AVFormatContext *);
34
typedef AVCodec* (*avcodec_find_decoder_t)(enum CodecID);
35
typedef int (*avcodec_open_t)(AVCodecContext *, AVCodec *);
36
typedef AVFrame * (*avcodec_alloc_frame_t)(void);
37
38
typedef int (*avpicture_get_size_t)(int , int , int );
39
typedef void * (*av_malloc_t)(unsigned int );
40
typedef int (*avpicture_fill_t)(AVPicture *, uint8_t *,int , int , int);
41
typedef int (*av_read_frame_t)(AVFormatContext *, AVPacket *);
42
43
typedef int (*avcodec_decode_video_t)(AVCodecContext *, AVFrame *,int *, uint8_t *, int );
44
typedef int (*img_convert_t)(AVPicture *, int , const AVPicture *, int ,int, int);
45
typedef void (*av_free_t)(void *);
46
typedef int (*avcodec_close_t)(AVCodecContext *);
47
typedef void (*av_close_input_file_t)(AVFormatContext *);
48
typedef int (*av_seek_frame_t)(AVFormatContext *,int,int64_t timestamp,int flags); 		typedef int64_t (*av_rescale_q_t)(int64_t , AVRational , AVRational )	;
49
typedef void (*avcodec_flush_buffers_t)(AVCodecContext *);
50
typedef void (*av_free_packet_t)(AVPacket *);
51
52
#ifdef HAVE_SWSCALE
53
typedef void (*sws_freeContext_t)(struct SwsContext *swsContext);
54
typedef struct SwsContext* (*sws_getContext_t)(int srcW, int srcH, int srcFormat, int dstW, int dstH, int dstFormat, int flags,
55
                                  SwsFilter *srcFilter, SwsFilter *dstFilter, double *param);
56
typedef int (*sws_scale_t)(struct SwsContext *context, uint8_t* src[], int srcStride[], int srcSliceY,int srcSliceH, uint8_t* dst[], int dstStride[]);
57
#endif
58
59
60
class k9AviDecode : public QObject
33
class k9AviDecode : public QObject
61
{
34
{
62
Q_OBJECT
35
Q_OBJECT
Lines 76-111 Link Here
76
	QString getError() const;
49
	QString getError() const;
77
	
50
	
78
private:
51
private:
79
    av_register_all_t av_register_all;
80
    av_open_input_file_t av_open_input_file;
81
    av_find_stream_info_t av_find_stream_info;
82
    avcodec_find_decoder_t avcodec_find_decoder;
83
    avcodec_open_t avcodec_open;
84
    avcodec_alloc_frame_t avcodec_alloc_frame;
85
    av_seek_frame_t av_seek_frame;
86
    avpicture_get_size_t avpicture_get_size;
87
    av_malloc_t av_malloc;
88
    avpicture_fill_t avpicture_fill;
89
    av_read_frame_t av_read_frame;
90
    avcodec_decode_video_t avcodec_decode_video;
91
    img_convert_t img_convert;
92
    av_free_t av_free;
93
    avcodec_close_t avcodec_close;
94
    av_close_input_file_t av_close_input_file;
95
    av_rescale_q_t av_rescale_q;
96
    av_gettime_t av_gettime;
97
    avcodec_flush_buffers_t avcodec_flush_buffers;
98
    av_free_packet_t av_free_packet;
99
#ifdef HAVE_SWSCALE
100
    sws_freeContext_t sws_freeContext;
101
    sws_getContext_t sws_getContext;
102
    sws_scale_t sws_scale;
103
#endif
104
    void *CodecHandle;
105
    void *FormatHandle;
106
    void *SwscaleHandle;
107
    int glibref;
108
109
    AVFormatContext *m_FormatCtx;
52
    AVFormatContext *m_FormatCtx;
110
    AVCodecContext *m_CodecCtx;
53
    AVCodecContext *m_CodecCtx;
111
    AVCodec *m_Codec;
54
    AVCodec *m_Codec;
(-)k9copy-2.3.8-Source.orig/src/import/k9importfiles.cpp (-1 / +4 lines)
Lines 17-23 Link Here
17
#include "k9tools.h"
17
#include "k9tools.h"
18
#include <QDockWidget>
18
#include <QDockWidget>
19
#include "images.h"
19
#include "images.h"
20
#include "dvdread.h"
20
#include <ifo_types.h>
21
#include <ifo_read.h>
22
#include <nav_read.h>
23
#include <nav_types.h>
21
#include <QMenu>
24
#include <QMenu>
22
#include <QCloseEvent>
25
#include <QCloseEvent>
23
#ifndef BACKLITE
26
#ifndef BACKLITE
(-)k9copy-2.3.8-Source.orig/src/import/k9newdvd.cpp (-3 / +4 lines)
Lines 24-32 Link Here
24
#include <qfileinfo.h>
24
#include <qfileinfo.h>
25
#include "k9cell.h"
25
#include "k9cell.h"
26
#include "k9ifo2.h"
26
#include "k9ifo2.h"
27
#include "nav_types.h"
27
#include <ifo_types.h>
28
#include "ifo_types.h"
28
#include <ifo_read.h>
29
#include "dvdread.h"
29
#include <nav_read.h>
30
#include <nav_types.h>
30
#include <QDir>
31
#include <QDir>
31
#ifndef BACKLITE
32
#ifndef BACKLITE
32
#include <kstandarddirs.h>
33
#include <kstandarddirs.h>
(-)k9copy-2.3.8-Source.orig/src/main/k9copy.cpp (-1 / +4 lines)
Lines 40-46 Link Here
40
#include "k9tools.h"
40
#include "k9tools.h"
41
#include <QDockWidget>
41
#include <QDockWidget>
42
#include "images.h"
42
#include "images.h"
43
#include "dvdread.h"
43
#include <ifo_types.h>
44
#include <ifo_read.h>
45
#include <nav_read.h>
46
#include <nav_types.h>
44
#include <QMenu>
47
#include <QMenu>
45
#include "k9dialogs.h"
48
#include "k9dialogs.h"
46
#include "k9assistant.h"
49
#include "k9assistant.h"
(-)k9copy-2.3.8-Source.orig/src/mpeg2/k9plaympeg2.cpp (-2 / +2 lines)
Lines 11-18 Link Here
11
//
11
//
12
#include "k9plaympeg2.h"
12
#include "k9plaympeg2.h"
13
#include "kdecmpeg2.h"
13
#include "kdecmpeg2.h"
14
#include "dvdnav.h"
15
14
15
#include <dvdnav.h>
16
#include <qapplication.h>
16
#include <qapplication.h>
17
17
18
k9PlayMPEG2::k9PlayMPEG2()
18
k9PlayMPEG2::k9PlayMPEG2()
Lines 50-56 Link Here
50
49
51
50
52
    /* open dvdnav handle */
51
    /* open dvdnav handle */
53
    if (dvdnav_open(&dvdnav, m_device.toUtf8(),m_dvd) != DVDNAV_STATUS_OK) {
52
    if (dvdnav_open(&dvdnav, m_device.toUtf8()) != DVDNAV_STATUS_OK) {
54
        setError("ERR:Error on dvdnav_open\n");
53
        setError("ERR:Error on dvdnav_open\n");
55
        return ;
54
        return ;
56
    }
55
    }
(-)k9copy-2.3.8-Source.orig/src/player/k9play.cpp (-4 / +6 lines)
Lines 14-28 Link Here
14
#include "k9cell.h"
14
#include "k9cell.h"
15
#include "k9vamps.h"
15
#include "k9vamps.h"
16
16
17
#include "dvdnav.h"
17
#include <dvdnav.h>
18
#include "dvdread.h"
18
#include <ifo_types.h>
19
#include <ifo_read.h>
20
#include <nav_read.h>
21
#include <nav_types.h>
19
#include <stdio.h>
22
#include <stdio.h>
20
#include <unistd.h>
23
#include <unistd.h>
21
#include <inttypes.h>
24
#include <inttypes.h>
22
#include <sys/types.h>
25
#include <sys/types.h>
23
#include <sys/stat.h>
26
#include <sys/stat.h>
24
#include <fcntl.h>
27
#include <fcntl.h>
25
#include "dvdread.h"
26
28
27
29
28
#ifdef BACKLITE
30
#ifdef BACKLITE
Lines 351-357 Link Here
351
    }
353
    }
352
354
353
    /* open dvdnav handle */
355
    /* open dvdnav handle */
354
    if (dvdnav_open(&dvdnav, m_device.toUtf8(),NULL) != DVDNAV_STATUS_OK) {
356
    if (dvdnav_open(&dvdnav, m_device.toUtf8()) != DVDNAV_STATUS_OK) {
355
        writeOutput("ERR:Error on dvdnav_open\n");
357
        writeOutput("ERR:Error on dvdnav_open\n");
356
        emit sigError(i18n("Error opening the DVD"));
358
        emit sigError(i18n("Error opening the DVD"));
357
        end();
359
        end();
(-)k9copy-2.3.8-Source.orig/src/player/main.cpp (-1 / +4 lines)
Lines 18-24 Link Here
18
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
18
 *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
19
 ***************************************************************************/
19
 ***************************************************************************/
20
20
21
#include "src/dvdnav/common.h"
21
#include <ifo_types.h>
22
#include <ifo_read.h>
23
#include <nav_read.h>
24
#include <nav_types.h>
22
#include "k9copy.h"
25
#include "k9copy.h"
23
#include "k9play.h"
26
#include "k9play.h"
24
#include <kapplication.h>
27
#include <kapplication.h>

Return to bug 505196