Skip to content

Commit 1d8b363

Browse files
committed
Share Module: Removed Sharing Service
1 parent d8dd4c9 commit 1d8b363

37 files changed

+7
-2005
lines changed

docs/using_cmake_build.txt

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Step 2) create a separate directory where you want to build the target.
1313

1414
Step 3) make the build system using cmake. Params in [] are optional and have
1515
been explained later in the document.
16-
~> cmake [-DWITH_FFMPEG=ON] [-DWITH_OCR=ON] [-DWITH_SHARING=ON]
16+
~> cmake [-DWITH_FFMPEG=ON] [-DWITH_OCR=ON]
1717
[-DWITH_HARDSUBX=ON] ../src/
1818

1919
Step 4) Compile the code.
@@ -29,9 +29,6 @@ cmake -DWITH_FFMPEG=ON ../src/
2929
If you want to build CCExtractor with OCR you need to pass
3030
cmake -DWITH_OCR=ON ../src/
3131

32-
If you want to build CCExtractor with Sharing and Translating service:
33-
cmake -DWITH_SHARING=ON ../src/
34-
3532
If you want to build CCExtractor with HARDSUBX support
3633
cmake -DWITH_HARDSUBX=ON ../src/
3734

linux/Makefile.am

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,6 @@ ccextractor_SOURCES = \
124124
../src/lib_ccx/ccx_gxf.h \
125125
../src/lib_ccx/ccx_mp4.h \
126126
../src/lib_ccx/ccx_share.c \
127-
../src/lib_ccx/ccx_share.h \
128127
../src/lib_ccx/ccx_sub_entry_message.pb-c.c \
129128
../src/lib_ccx/ccx_sub_entry_message.pb-c.h \
130129
../src/lib_ccx/compile_info.h \

mac/Makefile.am

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,6 @@ ccextractor_SOURCES = \
9696
../src/lib_ccx/ccx_gxf.h \
9797
../src/lib_ccx/ccx_mp4.h \
9898
../src/lib_ccx/ccx_share.c \
99-
../src/lib_ccx/ccx_share.h \
10099
../src/lib_ccx/ccx_sub_entry_message.pb-c.c \
101100
../src/lib_ccx/ccx_sub_entry_message.pb-c.h \
102101
../src/lib_ccx/compile_info.h \

src/CMakeLists.txt

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ include (CTest)
55

66
option (WITH_FFMPEG "Build using FFmpeg demuxer and decoder" OFF)
77
option (WITH_OCR "Build with OCR (Optical Character Recognition) feature" OFF)
8-
option (WITH_SHARING "Build with sharing and translation support" OFF)
98
option (WITH_HARDSUBX "Build with support for burned-in subtitles" OFF)
109
option (WITHOUT_RUST "Build without Rust library" OFF)
1110

@@ -206,21 +205,6 @@ if (PKG_CONFIG_FOUND AND WITH_OCR)
206205
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DENABLE_OCR")
207206
endif (PKG_CONFIG_FOUND AND WITH_OCR)
208207

209-
########################################################
210-
# Build with CC sharing and translation support
211-
########################################################
212-
213-
if (PKG_CONFIG_FOUND AND WITH_SHARING)
214-
215-
pkg_check_modules (NANOMSG REQUIRED libnanomsg)
216-
set (EXTRA_LIBS ${EXTRA_LIBS} ${NANOMSG_STATIC_LIBRARIES})
217-
218-
include_directories ("${PROJECT_SOURCE_DIR}/thirdparty/protobuf-c/")
219-
aux_source_directory ("${PROJECT_SOURCE_DIR}/thirdparty/protobuf-c/" SOURCEFILE)
220-
221-
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DENABLE_SHARING")
222-
endif (PKG_CONFIG_FOUND AND WITH_SHARING)
223-
224208
########################################################
225209
# Build for hardsubx using avformat, avutil, avcodec and
226210
# swscale

src/ccextractor.c

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -138,27 +138,10 @@ int api_start(struct ccx_s_options api_options)
138138
#endif
139139
terminate_asap = 0;
140140

141-
#ifdef ENABLE_SHARING
142-
if (api_options.translate_enabled && ctx->num_input_files > 1)
143-
{
144-
mprint("[share] WARNING: simultaneous translation of several input files is not supported yet\n");
145-
api_options.translate_enabled = 0;
146-
api_options.sharing_enabled = 0;
147-
}
148-
if (api_options.translate_enabled)
149-
{
150-
mprint("[share] launching translate service\n");
151-
ccx_share_launch_translator(api_options.translate_langs, api_options.translate_key);
152-
}
153-
#endif // ENABLE_SHARING
154141
ret = 0;
155142
while (switch_to_next_file(ctx, 0))
156143
{
157144
prepare_for_new_file(ctx);
158-
#ifdef ENABLE_SHARING
159-
if (api_options.sharing_enabled)
160-
ccx_share_start(ctx->basefilename);
161-
#endif // ENABLE_SHARING
162145

163146
stream_mode = ctx->demux_ctx->get_stream_mode(ctx->demux_ctx);
164147
// Disable sync check for raw formats - they have the right timeline.
@@ -310,14 +293,6 @@ int api_start(struct ccx_s_options api_options)
310293
dec_ctx->timing->fts_now = 0;
311294
dec_ctx->timing->fts_max = 0;
312295

313-
#ifdef ENABLE_SHARING
314-
if (api_options.sharing_enabled)
315-
{
316-
ccx_share_stream_done(ctx->basefilename);
317-
ccx_share_stop();
318-
}
319-
#endif // ENABLE_SHARING
320-
321296
if (dec_ctx->total_pulldownframes)
322297
mprint("incl. pulldown frames: %s (%u frames at %.2ffps)\n",
323298
print_mstime_static((LLONG)(dec_ctx->total_pulldownframes * 1000 / current_fps)),

src/ccextractor.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@
1919
#include "lib_ccx/ccx_common_option.h"
2020
#include "lib_ccx/ccx_mp4.h"
2121
#include "lib_ccx/hardsubx.h"
22-
#include "lib_ccx/ccx_share.h"
2322
#ifdef WITH_LIBCURL
2423
CURL *curl;
2524
CURLcode res;

src/lib_ccx/CMakeLists.txt

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,6 @@ if (WITH_OCR)
5656
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DENABLE_OCR")
5757
endif (WITH_OCR)
5858

59-
if (WITH_SHARING)
60-
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DENABLE_SHARING")
61-
endif (WITH_SHARING)
6259

6360
aux_source_directory ("${PROJECT_SOURCE_DIR}/lib_ccx/" SOURCEFILE)
6461

src/lib_ccx/ccx_common_constants.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,6 @@ enum ccx_debug_message_types
5858
CCX_DMT_LEVENSHTEIN = 0x1000, // Levenshtein distance calculations
5959
CCX_DMT_DVB = 0x2000, // DVB
6060
CCX_DMT_DUMPDEF = 0x4000 // Dump defective TS packets
61-
#ifdef ENABLE_SHARING
62-
CCX_DMT_SHARE = 0x8000, // Extracted captions sharing service
63-
#endif //ENABLE_SHARING
6461
};
6562

6663
// AVC NAL types

src/lib_ccx/ccx_common_option.c

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -151,13 +151,6 @@ void init_options(struct ccx_s_options *options)
151151
options->settings_dtvcc.services_enabled, 0,
152152
CCX_DTVCC_MAX_SERVICES * sizeof(options->settings_dtvcc.services_enabled[0]));
153153

154-
#ifdef ENABLE_SHARING
155-
options->sharing_enabled = 0;
156-
options->sharing_url = NULL;
157-
options->translate_enabled = 0;
158-
options->translate_key = NULL;
159-
options->translate_langs = NULL;
160-
#endif // ENABLE_SHARING
161154
#ifdef WITH_LIBCURL
162155
options->curlposturl = NULL;
163156
#endif

src/lib_ccx/ccx_common_option.h

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -198,17 +198,6 @@ struct ccx_s_options // Options from user parameters
198198
#ifdef WITH_LIBCURL
199199
char *curlposturl;
200200
#endif
201-
202-
203-
#ifdef ENABLE_SHARING
204-
//CC sharing
205-
int sharing_enabled;
206-
char *sharing_url;
207-
//Translating
208-
int translate_enabled;
209-
char *translate_langs;
210-
char *translate_key;
211-
#endif
212201
};
213202

214203
extern struct ccx_s_options ccx_options;

0 commit comments

Comments
 (0)