if [ $$d = picon/cinfinity ]; then continue; fi; \
cp -a $$d bin/plugins/picon/.; \
done
- cp -a db/utils/new_db "bin/cin_db"
+ -cp -a db/utils/new_db "bin/cin_db"
cp -av lv2_blacklist.txt bin/.
buninstall:
cd bin; $(inst_sh) "$(DESTDIR)$(bindir)" "$(WANT_CIN)" \
cin_db zmpeg3{cat,cc2txt,ifochk,show,toc}
cd bin; $(inst_sh) "$(DESTDIR)$(WANT_CINLIB_DIR)" \
- bdwrite cutads lv2ui hveg2enc mpeg2enc mplex mplexlo
+ bdwrite cutads lv2ui
+ -cd bin; $(inst_sh) "$(DESTDIR)$(WANT_CINLIB_DIR)" \
+ hveg2enc mpeg2enc mplex mplexlo
cd bin; $(inst_sh) "$(DESTDIR)$(datadir)/$(WANT_CIN)" \
COPYING README models Cinelerra_factory ffmpeg msg info tips doc \
lv2 lv2_blacklist.txt
jobs:=-j$(shell echo $$(($(cpus) + $(cpus)/2 +2)))
MAKEJ := $(MAKE) $(jobs)
-SUBDIRS := thirdparty libzmpeg3 mpeg2enc mplexlo\
- db guicast cinelerra plugins doc po
+SUBDIRS = thirdparty libzmpeg3 mpeg2enc mplexlo \
+ db guicast cinelerra plugins doc po
all:
mkdir -p bin bin/lv2
$(MAKE) -C libzmpeg3 clean
+$(MAKEJ) -C libzmpeg3
$(MAKE) -C db clean
- +$(MAKEJ) -C db
+ +$(MAKEJ) -C db all utils
$(MAKE) rebuild
- +$(MAKEJ) -C db/utils
rebuild_install:
$(MAKE) -C cinelerra install
--- /dev/null
+#!/bin/bash
+
+#pacman -S openexr libdv flac
+
+( ./autogen.sh
+ ./configure --with-single-user --disable-static-build --without-lv2 \
+ --without-firewire --without-dv --without-dvb --without-video4linux2 \
+ --without-libzmpeg --without-commercial --without-thirdparty
+ make && make install ) 2>&1 | tee log
+mv Makefile Makefile.cfg
+cp Makefile.devel Makefile
export TOPDIR ?= $(CURDIR)/..
include $(TOPDIR)/global_config
-OBJS = \
+OBJS := \
$(OBJDIR)/aattachmentpoint.o \
$(OBJDIR)/aautomation.o \
$(OBJDIR)/aboutprefs.o \
$(OBJDIR)/audiodvb.o \
$(OBJDIR)/audioesound.o \
$(OBJDIR)/audioidevice.o \
- $(OBJDIR)/audiompeg.o \
$(OBJDIR)/audioodevice.o \
$(OBJDIR)/audiooss.o \
$(OBJDIR)/audiov4l2mpeg.o \
$(OBJDIR)/clipedls.o \
$(OBJDIR)/clippopup.o \
$(OBJDIR)/colorpicker.o \
- $(OBJDIR)/commercials.o \
$(OBJDIR)/commonrender.o \
$(OBJDIR)/confirmquit.o \
$(OBJDIR)/confirmsave.o \
$(OBJDIR)/cwindowgui.o \
$(OBJDIR)/cwindow.o \
$(OBJDIR)/cwindowtool.o \
- $(OBJDIR)/dbwindow.o \
$(OBJDIR)/dcoffset.o \
$(OBJDIR)/deleteallindexes.o \
$(OBJDIR)/device1394input.o \
$(OBJDIR)/device1394output.o \
$(OBJDIR)/devicedvbinput.o \
- $(OBJDIR)/devicempeginput.o \
$(OBJDIR)/devicev4l2base.o \
$(OBJDIR)/devicev4l2input.o \
$(OBJDIR)/dragcheckbox.o \
$(OBJDIR)/drivesync.o \
- $(OBJDIR)/dvbtune.o \
$(OBJDIR)/dvdcreate.o \
$(OBJDIR)/edithandles.o \
$(OBJDIR)/editlength.o \
$(OBJDIR)/exportedl.o \
$(OBJDIR)/fadeengine.o \
$(OBJDIR)/ffmpeg.o \
- $(OBJDIR)/fileac3.o \
$(OBJDIR)/filebaseaudio.o \
$(OBJDIR)/filebase.o \
$(OBJDIR)/filebaseulaw.o \
$(OBJDIR)/filecr2.o \
- $(OBJDIR)/filedb.o \
$(OBJDIR)/filedv.o \
$(OBJDIR)/fileexr.o \
$(OBJDIR)/fileffmpeg.o \
$(OBJDIR)/filegif.o \
$(OBJDIR)/filejpeg.o \
$(OBJDIR)/filelist.o \
- $(OBJDIR)/filempeg.o \
$(OBJDIR)/file.o \
$(OBJDIR)/fileogg.o \
$(OBJDIR)/filepng.o \
$(OBJDIR)/maskautos.o \
$(OBJDIR)/maskengine.o \
$(OBJDIR)/mbuttons.o \
- $(OBJDIR)/mediadb.o \
$(OBJDIR)/menuaeffects.o \
$(OBJDIR)/menuattacheffect.o \
$(OBJDIR)/menuattachtransition.o \
$(OBJDIR)/vdevice1394.o \
$(OBJDIR)/vdevicebase.o \
$(OBJDIR)/vdevicedvb.o \
- $(OBJDIR)/vdevicempeg.o \
$(OBJDIR)/vdeviceprefs.o \
$(OBJDIR)/vdevicev4l2jpeg.o \
$(OBJDIR)/vdevicev4l2mpeg.o \
$(OBJDIR)/zwindow.o \
$(OBJDIR)/zwindowgui.o \
+ifneq ($(WANT_LIBZMPEG),no)
+OBJS += \
+ $(OBJDIR)/audiompeg.o \
+ $(OBJDIR)/devicempeginput.o \
+ $(OBJDIR)/filempeg.o \
+ $(OBJDIR)/vdevicempeg.o \
+
+endif
+ifneq ($(WANT_COMMERCIAL),no)
+OBJS += \
+ $(OBJDIR)/commercials.o \
+ $(OBJDIR)/dbwindow.o \
+ $(OBJDIR)/filedb.o \
+ $(OBJDIR)/mediadb.o \
+
+endif
+ifneq ($(WANT_CIN_3RDPARTY),no)
+OBJS += \
+ $(OBJDIR)/fileac3.o \
+
+endif
+
+# $(OBJDIR)/dvbtune.o \
# $(OBJDIR)/renderfarmfsclient.o \
# $(OBJDIR)/renderfarmfsserver.o \
LIBRARIES := \
$(GUICAST)/$(OBJDIR)/libguicast.a \
- $(LIBZMPEG3)/$(OBJDIR)/libzmpeg3.a \
+
+ifneq ($(WANT_LIBZMPEG),no)
+LIBRARIES += \
$(MPEG2ENC)/$(OBJDIR)/hveg2enc.a \
+ $(LIBZMPEG3)/$(OBJDIR)/libzmpeg3.a \
+
+endif
+ifneq ($(WANT_COMMERCIAL),no)
+LIBRARIES += \
$(TDB)/$(OBJDIR)/db.a \
+endif
+
LIBS := $(LIBRARIES)
+
+ifneq ($(WANT_CIN_3RDPARTY),no)
LIBS += $(libraries)
+else
+
+LIBS += -lpthread -lm -lbz2 -llzma -lz -lpng -luuid
+LIBS += -lX11 -lXau -lXdmcp -lXext -lXfixes -lXv -lXinerama
+LIBS += -lfontconfig -lfreetype
+LIBS += -lavcodec -lavdevice -lavfilter -lavformat -lavresample -lavutil
+LIBS += -lswresample -lswscale
+LIBS += -lvpx -lwebp -lwebpmux
+
+LIBS += $(if $(filter fftw,$(static_pkgs)), -lfftw3)
+LIBS += $(if $(filter flac,$(static_pkgs)), -lFLAC)
+LIBS += $(if $(filter giflib,$(static_pkgs)), -lgif)
+LIBS += $(if $(filter lame,$(static_pkgs)), -lmp3lame)
+LIBS += $(if $(filter libjpeg,$(static_pkgs)), -ljpeg)
+LIBS += $(if $(filter openjpeg,$(static_pkgs)), -lopenjp2)
+LIBS += $(if $(filter libogg,$(static_pkgs)), -logg)
+LIBS += $(if $(filter libsndfile,$(static_pkgs)), -lsndfile)
+LIBS += $(if $(filter libtheora,$(static_pkgs)), -ltheoradec -ltheoraenc)
+LIBS += $(if $(filter libuuid,$(static_pkgs)), -luuid)
+LIBS += $(if $(filter libvorbis,$(static_pkgs)), -lvorbis -lvorbisenc -lvorbisfile)
+LIBS += $(if $(filter tiff,$(static_pkgs)), -ltiff)
+LIBS += $(if $(filter twolame,$(static_pkgs)), -ltwolame)
+LIBS += $(if $(filter x264,$(static_pkgs)), -lx264)
+LIBS += $(if $(filter x265,$(static_pkgs)), -lx265)
+LIBS += $(if $(filter libvpx,$(static_pkgs)), -lvpx)
+
+ifneq ($(WANT_GL),no)
+LIBS += -lGL -lGLU -lGLX
+endif
+ifneq ($(WANT_XFT),no)
+LIBS += -lXft
+endif
+ifneq ($(WANT_ALSA),no)
+LIBS += -lasound
+endif
+ifneq ($(WANT_OPENEXR),no)
+LIBS += -lIex -lIexMath -lIlmImf -lIlmImfUtil
+endif
+ifneq ($(WANT_DV),no)
+LIBS += -ldv
+endif
+ifneq ($(WANT_FIREWIRE),no)
+LIBS += -lavc1394 -lraw1394 -liec61883 -lrom1394
+endif
+ifneq ($(WANT_DVB),no)
+LIBS += -ldv
+endif
+ifneq ($(WANT_DL),no)
+LIBS += -ldl
+endif
+ifneq ($(WANT_LIBZMPEG),no)
+LIBS += -lmjpegutils
+endif
+ifneq ($(WANT_OPUS),no)
+LIBS += -lopus
+endif
+ifneq ($(WANT_NUMA),no)
+LIBS += -lnuma
+endif
+ifneq ($(WANT_LV2),no)
+LIBS += -llilv-0 -lsratom-0 -lserd-0 -lsord-0 -lsuil-0
+endif
+endif
+ifneq ($(WANT_COMMERCIAL),no)
CUTADS = $(OBJDIR)/cutads
CUTOBJ = $(OBJDIR)/cutads.o
CUTOBJS = $(CUTOBJ) \
CUTLIBS = \
$(LIBZMPEG3)/$(OBJDIR)/libzmpeg3.a -lX11 \
$(TDB)/$(OBJDIR)/db.a
+endif
BDWRITE = $(OBJDIR)/bdwrite
BDWOBJS = $(OBJDIR)/bdwrite.o
$(if $(findstring -ggdb,$(CFLAGS)),,strip $(OUTPUT))
ln -f -s ../bin/$(WANT_CIN) ci
+ifneq ($(WANT_COMMERCIAL),no)
$(CUTADS): $(CUTOBJS) $(CUTLIBS) $(LIBRARIES)
@echo g++ -o $@ $(CUTOBJS)
@g++ $(CFLAGS) -pthread -o $@ $(CUTOBJS) $(CUTLIBS) $(LIBS)
install-cutads:
cp -av $(OBJDIR)/cutads $(BINDIR)/.
+
install: install-cutads
+endif
$(BDWRITE): $(BDWOBJS) $(LIBRARIES)
@echo g++ -o $@ $(BDWOBJS)
#include "bcsignals.h"
#include "file.h"
#include "language.h"
-#include "libzmpeg3.h"
#include "mwindow.h"
#include "theme.h"
#include "vframe.h"
strncpy(info,_("no info available"),len);
if( !mwindow->preferences->get_asset_file_path(asset, file_name) ) {
switch( asset->format ) {
+#ifdef HAVE_LIBZMPEG
case FILE_MPEG:
FileMPEG::get_info(asset->path, file_name, &info[0],len);
break;
+#endif
case FILE_FFMPEG:
FileFFMPEG::get_info(asset->path, &info[0],len);
break;
*
*/
-#include "../../guicast/bcwindowbase.inc"
-#include "../../guicast/clip.h"
+#include "guicast/bcwindowbase.inc"
+#include "guicast/clip.h"
#include "condition.h"
#include "devicedvbinput.inc"
#include "dvbtune.h"
#include "mwindow.h"
#include "vframe.h"
+#ifdef FFMPEG3
+#define url filename
+#else
+#define av_register_all(s)
+#define avfilter_register_all(s)
+#endif
#define VIDEO_INBUF_SIZE 0x10000
#define AUDIO_INBUF_SIZE 0x10000
int FFMPEG::init_decoder(const char *filename)
{
ff_lock("FFMPEG::init_decoder");
+ av_register_all();
char file_opts[BCTEXTLEN];
char *bp = strrchr(strcpy(file_opts, filename), '/');
char *sp = strrchr(!bp ? file_opts : bp, '.');
return 1;
}
ff_lock("FFMPEG::init_encoder");
+ av_register_all();
char format[BCSTRLEN];
if( get_format(format, "format", file_format) )
strcpy(format, file_format);
return 1;
}
+#ifdef HAVE_DV
if( !strcmp(codec_name, CODEC_TAG_DVSD) ) strcpy(codec_name, "dv");
+#endif
else if( !strcmp(codec_name, CODEC_TAG_MJPEG) ) strcpy(codec_name, "mjpeg");
else if( !strcmp(codec_name, CODEC_TAG_JPEG) ) strcpy(codec_name, "jpeg");
int FFVideoStream::create_filter(const char *filter_spec, AVCodecParameters *avpar)
{
+ avfilter_register_all();
const char *sp = filter_spec;
char filter_name[BCSTRLEN], *np = filter_name;
int i = sizeof(filter_name);
int FFAudioStream::create_filter(const char *filter_spec, AVCodecParameters *avpar)
{
+ avfilter_register_all();
const char *sp = filter_spec;
char filter_name[BCSTRLEN], *np = filter_name;
int i = sizeof(filter_name);
getting_options = 1;
format_completion->lock("File::get_options");
switch( asset->format ) {
+#ifdef HAVE_CIN_3RDPARTY
case FILE_AC3: FileAC3::get_parameters(parent_window, asset, format_window,
audio_options, video_options, edl);
break;
+#endif
#ifdef HAVE_DV
case FILE_RAWDV:
FileDV::get_parameters(parent_window, asset, format_window,
FileFFMPEG::get_parameters(parent_window, asset, format_window,
audio_options, video_options, edl);
break;
+#ifdef HAVE_LIBZMPEG
case FILE_AMPEG:
case FILE_VMPEG:
FileMPEG::get_parameters(parent_window, asset, format_window,
audio_options, video_options, edl);
break;
+#endif
case FILE_JPEG:
case FILE_JPEG_LIST:
FileJPEG::get_parameters(parent_window, asset, format_window,
file = new FileFFMPEG(this->asset, this);
return FILE_OK;
}
+#ifdef HAVE_COMMERCIAL
if( !strcmp(pref->name,"DB") ) { // MediaDB
if( !FileDB::check_sig(this->asset) ) continue;
file = new FileDB(this->asset, this);
return FILE_OK;
}
+#endif
if( !strcmp(pref->name,"Scene") ) { // scene file
if( !FileScene::check_sig(this->asset, data)) continue;
file = new FileScene(this->asset, this);
file = new FileVorbis(this->asset, this);
return FILE_OK;
}
+#ifdef HAVE_LIBZMPEG
if( !strcmp(pref->name,"MPEG") ) { // MPEG file
if( !FileMPEG::check_sig(this->asset) ) continue;
file = new FileMPEG(this->asset, this);
return FILE_OK;
}
+#endif
if( !strcmp(pref->name,"EDL") ) { // XML file
if( data[0] != '<' ) continue;
if( !strncmp(&data[1],"EDL>",4) ||
if( ret != FILE_OK ) return ret;
break; }
// format already determined
+#ifdef HAVE_CIN_3RDPARTY
case FILE_AC3:
file = new FileAC3(this->asset, this);
break;
-
+#endif
case FILE_SCENE:
file = new FileScene(this->asset, this);
break;
case FILE_TIFF_LIST:
file = new FileTIFF(this->asset, this);
break;
-
+#ifdef HAVE_COMMERCIAL
case FILE_DB:
file = new FileDB(this->asset, this);
break;
+#endif
+#ifdef HAVE_LIBZMPEG
case FILE_MPEG:
case FILE_AMPEG:
case FILE_VMPEG:
file = new FileMPEG(this->asset, this);
break;
-
+#endif
case FILE_OGG:
file = new FileOGG(this->asset, this);
break;
case FILE_FLAC: return _(FLAC_NAME);
case FILE_EXR: return _(EXR_NAME);
case FILE_EXR_LIST: return _(EXR_LIST_NAME);
+#ifdef HAVE_LIBZMPEG
case FILE_MPEG: return _(MPEG_NAME);
+#endif
case FILE_AMPEG: return _(AMPEG_NAME);
case FILE_VMPEG: return _(VMPEG_NAME);
case FILE_TGA: return _(TGA_NAME);
#ifdef HAVE_DV
case FILE_RAWDV: return FileDV::get_best_colormodel(asset, driver);
#endif
+#ifdef HAVE_LIBZMPEG
case FILE_MPEG: return FileMPEG::get_best_colormodel(asset, driver);
+#endif
case FILE_JPEG:
case FILE_JPEG_LIST: return FileJPEG::get_best_colormodel(asset, driver);
#ifdef HAVE_OPENEXR
case FILE_TGA_LIST: return FileTGA::get_best_colormodel(asset, driver);
case FILE_CR2:
case FILE_CR2_LIST: return FileCR2::get_best_colormodel(asset, driver);
+#ifdef HAVE_COMMERCIAL
case FILE_DB: return FileDB::get_best_colormodel(asset, driver);
+#endif
case FILE_FFMPEG: return FileFFMPEG::get_best_colormodel(asset, driver);
}
-
+#ifdef HAVE_CIN_3RDPARTY
/*
* CINELERRA
* Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
return 1;
}
-
-
+#endif
-
/*
* CINELERRA
* Copyright (C) 2008 Adam Williams <broadcast at earthling dot net>
#ifndef FILEAC3_H
#define FILEAC3_H
+#ifdef HAVE_CIN_3RDPARTY
#include <stdio.h>
#include <stdint.h>
AC3ConfigAudio *gui;
};
-
-
-
-
+#endif
#endif
#ifdef HAVE_DV
-#include "../config.h"
#include "edl.inc"
#include "filebase.h"
#include "file.inc"
#include "preferences.h"
#include "videodevice.inc"
+#ifdef FFMPEG3
+#define url filename
+#endif
+
FileFFMPEG::FileFFMPEG(Asset *asset, File *file)
: FileBase(asset, file)
{
+#ifdef HAVE_COMMERCIAL
int FileMPEG::toc_nail(void *vp, int track)
{
File *file = (File *)vp;
MWindow::commercials->get_frame(file, pid, position, tdat, mw, mh, width, height);
return 0;
}
-
+#endif
int FileMPEG::create_toc(char *toc_path)
{
// File needs a table of contents.
struct timeval new_time, prev_time, start_time, current_time;
gettimeofday(&prev_time, 0); gettimeofday(&start_time, 0);
+#ifdef HAVE_COMMERCIAL
if( file->preferences->scan_commercials ) {
set_skimming(-1, 1, toc_nail, file);
if( MWindow::commercials->resetDb() != 0 )
eprintf(_("cant access commercials database"));
}
+#endif
// This gets around the fact that MWindowGUI may be locked.
char progress_title[BCTEXTLEN];
sprintf(progress_title, _("Creating %s\n"), toc_file);
}
}
+#ifdef HAVE_COMMERCIAL
if( file->preferences->scan_commercials ) {
if( !result ) MWindow::commercials->write_ads(asset->path);
MWindow::commercials->closeDb();
}
+#endif
mpeg3_stop_toc(fd);
fd = 0;
#ifndef FILEMPEG_H
#define FILEMPEG_H
+#ifdef HAVE_LIBZMPEG
#include "bitspopup.inc"
#include "condition.inc"
ArrayList<BC_SubWindow*> tools;
};
-
+#endif
#endif
#ifndef FILEOGG_H
#define FILEOGG_H
-#include "../config.h"
#include "edl.inc"
#include "filebase.h"
#include "file.inc"
#ifdef HAVE_DVB
filemenu->add_item(new ChannelScan(mwindow));
#endif
+#ifdef HAVE_COMMERCIAL
if( mwindow->has_commercials() )
filemenu->add_item(new DbWindowScan(mwindow));
+#endif
filemenu->add_item(new SubttlSWin(mwindow));
filemenu->add_item(render = new RenderItem(mwindow));
int MWindow::has_commercials()
{
+#ifdef HAVE_COMMERCIAL
return theme->use_commercials;
+#else
+ return 0;
+#endif
}
void MWindow::init_commercials()
{
+#ifdef HAVE_COMMERCIAL
if( !commercials ) {
commercials = new Commercials(this);
commercial_active = 0;
}
else
commercials->add_user();
+#endif
}
void MWindow::commit_commercial()
{
+#ifdef HAVE_COMMERCIAL
if( !commercial_active ) return;
commercial_active = 0;
if( !commercials ) return;
commercials->commitDb();
+#endif
}
void MWindow::undo_commercial()
{
+#ifdef HAVE_COMMERCIAL
if( !commercial_active ) return;
commercial_active = 0;
if( !commercials ) return;
commercials->undoDb();
+#endif
}
int MWindow::put_commercial()
{
+ int result = 0;
+#ifdef HAVE_COMMERCIAL
double start = edl->local_session->get_selectionstart();
double end = edl->local_session->get_selectionend();
if( start >= end ) return 0;
const char *errmsg = 0;
int count = 0;
Tracks *tracks = edl->tracks;
- int result = 0;
//check it
for(Track *track=tracks->first; track && !errmsg; track=track->next) {
if( track->data_type != TRACK_VIDEO ) continue;
undo_commercial();
result = 1;
}
+#endif
return result;
}
void MWindow::cut_commercials()
{
+#ifdef HAVE_COMMERCIAL
undo->update_undo_before();
commercials->scan_media();
edl->optimize();
gui->update(1, 2, 1, 1, 1, 1, 0);
cwindow->update(1, 0, 0, 0, 1);
cwindow->refresh_frame(CHANGE_EDL);
+#endif
}
int MWindow::normalize_speed(EDL *old_edl, EDL *new_edl)
#ifdef HAVE_DVB
channel_info = new ChannelInfo(mwindow);
#endif
+#ifdef HAVE_COMMERCIAL
db_window = new DbWindow(mwindow);
+#endif
swindow = new SWindow(mwindow);
if(debug) printf("MWindowGUI::create_objects %d\n", __LINE__);
#include "vframe.h"
#include "filexml.h"
+#ifdef FFMPEG3
+#define av_filter_iterate(p) ((*(const AVFilter**)(p))=avfilter_next(*(const AVFilter **)(p)))
+#endif
static void ff_err(int ret, const char *fmt, ...)
{
adevice_lock = new Mutex("Record::adevice_lock");
vdevice_lock = new Mutex("Record::vdevice_lock");
batch_lock = new Mutex("Record::batch_lock");
+#ifdef HAVE_COMMERCIAL
skim_thread = new SkimDbThread();
cutads_status = new RecordCutAdsStatus(this);
blink_status = new RecordBlinkStatus(this);
+#endif
}
Record::~Record()
{
mwindow->gui->record = 0;
stop();
+#ifdef HAVE_COMMERCIAL
delete blink_status;
delete cutads_status;
stop_skimming();
delete skim_thread;
+#endif
delete deletions;
delete picture;
delete channeldb;
// Need to stop everything this time
- stop_commercial_capture(0);
int video_stream = -1;
+#ifdef HAVE_COMMERCIAL
+ stop_commercial_capture(0);
+#endif
+#ifdef HAVE_LIBZMPEG
if( default_asset->format == FILE_MPEG ) {
Channel *channel = get_current_channel();
if( channel )
video_stream = channel->video_stream;
}
+#endif
stop(0);
edl->Garbage::remove_user();
return result;
}
-
+#ifdef HAVE_COMMERCIAL
int Record::skimming(void *vp, int track)
{
return ((Record*)vp)->skimming(track);
stop_skimming();
}
+#else
+int Record::skimming(void *vp, int track) { return 1; }
+int Record::skimming(int track) { return 1; }
+void Record::start_skimming() {}
+void Record::stop_skimming() {}
+void Record::update_skimming(int v) {}
+#endif
+
RecordRemoteHandler::RecordRemoteHandler(RemoteControl *remote_control)
: RemoteHandler(remote_control->gui, GREEN)
{
break;
//case UP: case DOWN: case LEFT: case RIGHT:
//case KPPLAY: case KPBACK: case KPFORW:
+#ifdef HAVE_COMMERCIAL
case KPRECD: case 'c': // start capture, mark endpoint
if( !deletions ) {
start_commercial_capture();
case KPAUSE: case 'x': // ignore current commercial
mark_commercial_capture(DEL_SKIP);
break;
+#endif
case KPBACK: case 'a': // toggle mute audio
if( !monitor_audio ) { set_mute_gain(1); set_play_gain(1); }
set_audio_monitoring(monitor_audio ? 0 : 1);
case 'm': // toggle metering audio
set_audio_metering(metering_audio ? 0 : 1);
break;
+#ifdef HAVE_COMMERCIAL
case KPPLAY: case 's': // ignore previous endpoint
mark_commercial_capture(DEL_OOPS);
break;
+#endif
case KPFWRD: case KPSLASH:
display_channel_info();
break;
return 1;
}
-
+#ifdef HAVE_COMMERCIAL
int Record::start_commercial_capture()
{
if( deletions != 0 ) return 1;
deletions->append(new Dele(time, action));
return 0;
}
+#endif
void Record::remote_fill_color(int color)
{
if( adevice ) adevice->set_play_gain(gain);
}
+#ifdef HAVE_COMMERCIAL
int Record::stop_commercial_capture(int run_job)
{
if( deletions == 0 ) return 1;
remote_color(record->status_color);
}
+#endif
void RenderFarmClientThread::do_tuner(int socket_fd)
{
// Currently only 1 tuner driver. Maybe more someday.
- DVBTune server(this);
- server.main_loop();
- ::close(socket_fd);
+// DVBTune server(this);
+// server.main_loop();
+// ::close(socket_fd);
}
CFG_CFLAGS+=" -DPNG_SKIP_SETJMP_CHECK=1"
CFG_CFLAGS+=" -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64"
CFG_CFLAGS+=" -I/usr/include/freetype2"
+CFG_CFLAGS+=" -I/usr/include/uuid"
+CFG_CFLAGS+=" -I/usr/include/mjpegtools"
AC_DEFUN([CHECK_WITH], [
AC_ARG_WITH([$1],
CHECK_WITH([browser],[cin_browser path],[CIN_BROWSER],[firefox])
CHECK_WITH([git-ffmpeg],[git ffmpeg using url],[GIT_FFMPEG],[no])
CHECK_WITH([noelision],[use noelision/libpthread],[NOELISION],[auto])
+CHECK_WITH([libzmpeg],[build libzmpeg],[LIBZMPEG],[yes])
+CHECK_WITH([commercial],[enable commercial capture],[COMMERCIAL],[yes])
+CHECK_WITH([thirdparty],[use thirdparty build],[CIN_3RDPARTY],[yes])
if test "x$WANT_LV2" != "xno"; then
GTK2_LIBS=`pkg-config --libs gtk+-2.0`
fi
fi
+if test "x$WANT_COMMERCIAL" = "xyes" -a "x$WANT_LIBZMPEG" != "xyes" ; then
+ AC_MSG_ERROR([commercial requires libzmpeg support.])
+fi
+
if test "x$WANT_CINBIN_BUILD" = "xyes"; then
WANT_LOCALE_DIR='$$CIN_LIB/locale'
test "x$WANT_CINDAT_DIR" = "xauto" && WANT_CINDAT_DIR='$$CIN_PATH'
SHARED_LIBS+="$SHARED_$1"
echo "AC_HELP_STRING([shared],[$1])"
])
+
AC_DEFUN([PKG_STATIC],[
- PKG_$1="yes"
- BUILD_$1=1
- AC_SUBST(BUILD_$1)
- STATIC_BLDS+=" [$1]"
- echo "AC_HELP_STRING([$2],[$1])"
+ if test "x$WANT_CIN_3RDPARTY" != "xno"; then
+ PKG_$1="yes"
+ BUILD_$1=1
+ AC_SUBST(BUILD_$1)
+ STATIC_BLDS+=" [$1]"
+ echo "AC_HELP_STRING([$2],[$1])"
+ fi
])
+
AC_DEFUN([PKG_FORCED],[PKG_STATIC([$1],[forced])])
+if test "x$WANT_CIN_3RDPARTY" != "xno"; then
# order matters
for dep in \
ffmpeg/twolame ffmpeg/lame ffmpeg/openjpeg \
eval "PKG_$needs=yes"
fi
done
+fi
AC_DEFUN([PKG_PROVIDE],[
if test "x$BUILD_$1" = "x" ; then
AC_SUBST(SYSTEM_LIBS)
echo ""
+if test "x$WANT_CIN_3RDPARTY" != "xno"; then
+ CFG_CFLAGS+=" -DHAVE_CIN_3RDPARTY"
+fi
for v in GL XFT XXF86VM OSS ALSA FIREWIRE DV DVB \
- VIDEO4LINUX2 ESOUND PACTL OPENEXR LV2; do
+ VIDEO4LINUX2 ESOUND PACTL OPENEXR LV2 \
+ COMMERCIAL LIBZMPEG; do
eval vv="\$WANT_$v"
if test "x$vv" != "xno"; then
CFG_CFLAGS+=" -DHAVE_$v"
echo " using: with-opencv = $WANT_OPENCV"
echo " using: with-git-ffmpeg = $WANT_GIT_FFMPEG"
echo " using: with-noelision = $WANT_NOELISION"
+echo " using: with-libzmpeg = $WANT_LIBZMPEG"
+echo " using: with-commerical = $WANT_COMMERCIAL"
echo ""
+echo " using: thirdparty build = $WANT_CIN_3RDPARTY"
echo " using: single-user = $WANT_CINBIN_BUILD"
echo " using: static-build = $WANT_STATIC_BUILD"
echo " using: ladspa-build = $WANT_LADSPA_BUILD"
fi
if test "x$WANT_OPUS" = "xyes"; then
FFMPEG_EXTRA_CFG+=' --enable-libopus'
- if "x$HAVE_OPUS" = "xyes" -a "x$BUILD_opus" = "x0"; then
+ if test "x$HAVE_OPUS" = "xyes" -a "x$BUILD_opus" = "x0"; then
EXTRA_LIBS+=' -lopus'
CFG_CFLAGS+=' -I/usr/include/opus'
fi
| tail -1`
fi
+AC_SUBST(WANT_CIN_3RDPARTY)
AC_SUBST(EXTRA_LIBS)
AC_SUBST(FFMPEG_EXTRA_CFG)
AC_SUBST(WANT_X264_HIDEPTH)
echo ""
echo "WANT_CIN := $WANT_CIN"
+CFG_WANTS+=" CIN_3RDPARTY LIBZMPEG COMMERCIAL"
for w in $CFG_WANTS; do ww=WANT_$w; echo "WANT_$w := ${!ww}"; done
echo ""
export TOPDIR ?= $(CURDIR)/..
include $(TOPDIR)/global_config
+ifneq ($(WANT_COMMERCIAL),no)
+
$(shell mkdir -p $(OBJDIR))
LIBS := $(OBJDIR)/db.a ../libzmpeg3/$(OBJDIR)/libzmpeg3.a -lasound -lm -lX11
OUTPUT := $(OBJDIR)/db.a s.C
$(OBJDIR)/xsch.o: xsch.C tdb.h
$(OBJDIR)/xsch: $(OBJDIR)/xsch.o
+else
+#not WANT_COMMERCIAL
+all:
+rebuild:
+utils:
+install:
+clean:
+endif
export TOPDIR ?= $(CURDIR)/../..
include $(TOPDIR)/global_config
+ifneq ($(WANT_COMMERCIAL),no)
+
$(shell mkdir -p $(OBJDIR))
$(shell echo $(CFLAGS) > $(OBJDIR)/c_flags)
CXXFLAGS:=-ggdb -I.. -Wall `cat $(OBJDIR)/c_flags`
clean:
rm -f $(TARGETS) *.o a.out
+else
+#not WANT_COMMERCIAL
+all:
+install:
+clean:
+endif
--- /dev/null
+#!/bin/bash
+
+#apt install libavcodec-dev libavdevice-dev libavfilter-dev libavformat-dev \
+# libavresample-dev libavutil-dev uuid-dev libdv4-dev libmjpegtools-dev \
+# liblilv-dev libsuil-dev libavc1394-dev libraw1394-dev libmp3lame-dev \
+# libopenjp2-7-dev libtwolame-dev libvpx-dev libwebp-dev libwebpmux3 \
+# libx264-dev libx265-dev libopus-dev
+
+( ./autogen.sh
+ CFLAGS=-DFFMPEG3 ./configure --with-single-user \
+ --disable-static-build --without-thirdparty \
+ --without-video4linux2 --without-dvb --with-lv2=auto \
+ --without-libzmpeg --without-commercial
+ make && make install ) 2>&1 | tee log
+mv Makefile Makefile.cfg
+cp Makefile.devel Makefile
+
export TOPDIR ?= $(CURDIR)/..
include $(TOPDIR)/global_config
+ifneq ($(WANT_LIBZMPEG),no)
+
CC = gcc
NASM = nasm
USE_MMX ?= 0
$(OBJDIR)/audio/%.o: audio/%.C
$(OBJDIR)/video/%.o: video/%.C
+else
+#not WANT_LIBZMPEG
+all:
+rebuild:
+utils:
+clean:
+install:
+endif
#ifndef LIBMPEG3_H
#define LIBMPEG3_H
+#ifdef HAVE_LIBZMPEG
/* for quicktime build */
#define MAXFRAMESAMPLES 65536
}
#endif
#endif
+#endif
export TOPDIR ?= $(CURDIR)/..
include $(TOPDIR)/global_config
+ifneq ($(WANT_LIBZMPEG),no)
+
CC = gcc
CFLAGS += -I$(TOPDIR)/libzmpeg3
val-%:
@echo $($(subst val-,,$@))
+else
+#not WANT_LIBZMPEG
+all:
+rebuild:
+utils:
+clean:
+install:
+endif
export TOPDIR ?= $(CURDIR)/..
include $(TOPDIR)/global_config
+ifneq ($(WANT_LIBZMPEG),no)
+
$(shell mkdir -p $(OBJDIR))
OBJS = $(OBJDIR)/mplex.o
CC = gcc
cp $(OUTPUT) $(BINDIR)/.
$(OBJDIR)/mplex.o: mplex.c
+
+else
+#not WANT_LIBZMPEG
+all:
+rebuild:
+utils:
+clean:
+install:
+endif
--- /dev/null
+#!/bin/bash
+
+#zypper install ffmpeg \
+# libavc1394-devel libavcodec-devel libavdevice-devel libavfilter-devel \
+# libavformat-devel libavresample-devel libavutil-devel libmp3lame-devel \
+# libopus-devel libossp-uuid++16 libossp-uuid16 libossp-uuid_dce16 \
+# libtwolame-devel libvpx-devel libwebp-devel libwebpdecoder2 libwebpextras0 \
+# uuid-devel liblilv-0-devel suil-devel libmjpegutils-devel \
+# libogg-devel libvorbis-devel libtheora-devel libXdmcp-devel
+
+( ./autogen.sh
+ CFLAGS="-DFFMPEG3 -I/usr/include/ffmpeg" ./configure \
+ --with-single-user --disable-static-build --without-thirdparty \
+ --without-video4linux2 --without-dvb --with-lv2=auto \
+ --without-libzmpeg --without-commercial \
+ --disable-x264 --disable-x265 --disable-openjpeg
+ make && make install ) 2>&1 | tee log
+mv Makefile Makefile.cfg
+cp Makefile.devel Makefile
+
-include $(TOPDIR)/cin_config
BLD := $(THIRDPARTY)/build
+ifneq ($(WANT_CIN_3RDPARTY),no)
+
# package build flags, if needed
# need frame pointer for debugs and helps with profiling
# NOTE: the trailing blank is MANDITORY or the builds fail
install:
cp -a $(ver_mjpegtools)/mpeg2enc/mpeg2enc $(BINDIR)/.
cp -a $(ver_mjpegtools)/mplex/mplex $(BINDIR)/.
+else
+# not WANT_CIN_3RDPARTY
+all:
+clean:
+install:
+endif
val-%:
@echo $($(subst val-,,$@))