OSDN Git Service

import original 0.9.5 release
[handbrake-jp/handbrake-jp.git] / gtk / src / hb-backend.h
index 92b006f..547415c 100644 (file)
@@ -18,6 +18,7 @@
 #define _HBBACKEND_H_
 
 #include "settings.h"
+#include "hb.h"
 
 enum
 {
@@ -59,15 +60,21 @@ typedef struct
 #define GHB_PIC_KEEP_DISPLAY_HEIGHT 0x08
 #define GHB_PIC_KEEP_DAR            0x10
 #define GHB_PIC_KEEP_PAR            0x20
+#define GHB_PIC_USE_MAX             0x40
 
 typedef struct
 {
+       gchar *path;
+       gchar *name;
+       gint index;
+       gint type;
        gint width;
        gint height;
        gint crop[4];
        gint num_chapters;
        gint rate;
        gint rate_base;
+       gint interlaced;
        gint aspect_n;
        gint aspect_d;
        gint hours;
@@ -77,13 +84,6 @@ typedef struct
        gint angle_count;
 } ghb_title_info_t;
 
-typedef struct
-{
-       gint codec;
-       gint bitrate;
-       gint samplerate;
-} ghb_audio_info_t;
-
 #define GHB_AUDIO_SAMPLERATE 1
 #define GHB_AUDIO_BITRATE 2
 #define GHB_FRAMERATE 3
@@ -119,19 +119,21 @@ gint ghb_get_scan_state();
 gint ghb_get_queue_state();
 void ghb_get_status(ghb_status_t *status);
 void ghb_track_status(void);
-void ghb_backend_scan(const gchar *path, gint titleindex, gint preview_count);
+void ghb_backend_scan(const gchar *path, gint titleindex, gint preview_count, guint64 min_duration);
+void ghb_backend_scan_stop();
 void ghb_backend_queue_scan(const gchar *path, gint titleindex);
 gboolean ghb_get_title_info(ghb_title_info_t *tinfo, gint titleindex);
 void ghb_par_init(signal_user_data_t *ud);
 void ghb_set_scale(signal_user_data_t *ud, gint mode);
 GValue* ghb_get_chapters(gint titleindex);
 void ghb_get_chapter_duration(gint ti, gint ii, gint *hh, gint *mm, gint *ss);
-gint ghb_get_best_mix(gint titleindex, gint track, gint acodec, gint mix);
+void ghb_part_duration(gint tt, gint sc, gint ec, gint *hh, gint *mm, gint *ss);
+gint ghb_get_best_mix(hb_audio_config_t *aconfig, gint acodec, gint mix);
 gboolean ghb_ac3_in_audio_list(const GValue *audio_list);
 gboolean ghb_audio_is_passthru(gint acodec);
+gboolean ghb_audio_can_passthru(gint acodec);
 gint ghb_get_default_acodec(void);
-gboolean ghb_get_audio_info(
-       ghb_audio_info_t *ainfo, gint titleindex, gint audioindex);
+hb_audio_config_t* ghb_get_scan_audio_info(gint titleindex, gint audioindex);
 void ghb_set_passthru_bitrate_opts(GtkBuilder *builder, gint bitrate);
 void ghb_set_default_bitrate_opts(
        GtkBuilder *builder, gint first_rate, gint last_rate);
@@ -140,7 +142,8 @@ void ghb_update_ui_combo_box(
        signal_user_data_t *ud, const gchar *name, gint user_data, gboolean all);
 gchar* ghb_get_source_audio_lang(gint titleindex, gint track);
 gint ghb_find_audio_track(
-       gint titleindex, const gchar *lang, gint acodec, GHashTable *track_indices);
+       gint titleindex, const gchar *lang, gint acodec, 
+       gint fallback_acodec, GHashTable *track_indices);
 void ghb_add_all_subtitles(signal_user_data_t *ud, gint titleindex);
 gint ghb_find_pref_subtitle_track(const gchar *lang);
 gint ghb_find_subtitle_track(
@@ -158,6 +161,7 @@ gchar* ghb_dvd_volname(const gchar *device);
 gint ghb_get_title_number(gint titleindex);
 gint ghb_subtitle_track_source(signal_user_data_t *ud, gint track);
 const char* ghb_subtitle_track_source_name(signal_user_data_t *ud, gint track);
+const char* ghb_subtitle_source_name(gint source);
 gchar* ghb_subtitle_track_lang(signal_user_data_t *ud, gint track);
 
 gboolean ghb_validate_vquality(GValue *settings);
@@ -172,7 +176,8 @@ gdouble ghb_lookup_combo_double(const gchar *name, const GValue *gval);
 const gchar* ghb_lookup_combo_option(const gchar *name, const GValue *gval);
 const gchar* ghb_lookup_combo_string(const gchar *name, const GValue *gval);
 gchar* ghb_get_tmp_dir();
-gint ghb_select_audio_codec(signal_user_data_t *ud, gint track);
-const gchar* ghb_select_audio_codec_str(signal_user_data_t *ud, gint track);
+gint ghb_select_audio_codec(GValue *settings, hb_audio_config_t *aconfig, gint acodec);
+gint ghb_find_closest_audio_rate(gint rate);
+GValue* ghb_lookup_acodec_value(gint val);
 
 #endif // _HBBACKEND_H_