LiVES  2.8.4
main.h
Go to the documentation of this file.
1 // main.h
2 // LiVES
3 // (c) G. Finch (salsaman@gmail.com) 2003 - 2017
4 // see file ../COPYING for full licensing details
5 
6 /* This program is free software; you can redistribute it and/or modify
7  it under the terms of the GNU General Public License version 3 or higher as
8  published by the Free Software Foundation.
9 
10  This program is distributed in the hope that it will be useful,
11  but WITHOUT ANY WARRANTY; without even the implied warranty of
12  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  GNU General Public License for more details.
14 
15  You should have received a copy of the GNU General Public License
16  along with this program; if not, write to the Free Software
17  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
18 */
19 
20 
21 // begin legal warning
22 /*
23  NO WARRANTY
24 
25  BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
26  FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
27 OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
28  PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
29  OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
30 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
31 TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
32  PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
33 REPAIR OR CORRECTION.
34 
35  IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
36  WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
37  REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
38  INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
39  OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
40 TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
41 YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
42  PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
43 POSSIBILITY OF SUCH DAMAGES.
44 */
45 // end legal warning
46 
47 
48 // Have fun, and let's fight for Free Speech, Open Media and True Creativity !
49 // - Salsaman
50 
51 
52 // note: preferred coding style is: astyle --style=java -H -Y -s2 -U -k3 -W3 -xC140 -xL
53 
54 #ifndef HAS_LIVES_MAIN_H
55 #define HAS_LIVES_MAIN_H
56 
57 #ifdef __cplusplus
58 #undef HAVE_UNICAP
59 #endif
60 
61 #ifndef GUI_QT
62 #define GUI_GTK
63 #define PAINTER_CAIRO
64 #else
65 #define PAINTER_QPAINTER
66 #define NO_PROG_LOAD
67 #undef ENABLE_GIW
68 #endif
69 
70 #ifdef GUI_GTK
71 
72 #define USE_GLIB
73 
74 #include <gtk/gtk.h>
75 #include <gdk/gdkkeysyms.h>
76 
77 #if GTK_CHECK_VERSION(3,0,0)
78 #ifdef ENABLE_GIW
79 #define ENABLE_GIW_3
80 #endif
81 #endif
82 
83 #endif
84 
85 #ifdef IS_MINGW
86 
87 #ifndef WINVER
88 #define WINVER 0x0500
89 #endif
90 
91 #include <windows.h>
92 #include <winbase.h>
93 #include <tlhelp32.h>
94 #include <sddl.h>
95 
96 #define O_SYNC (FILE_FLAG_NO_BUFFERING|FILE_FLAG_WRITE_THROUGH)
97 
98 typedef PROCESS_INFORMATION *lives_pid_t;
99 typedef PROCESS_INFORMATION *lives_pgid_t;
100 
101 #ifdef GUI_GTK
102 #ifndef GDK_WINDOWING_WIN32
103 #define GDK_WINDOWING_WIN32
104 #endif
105 #endif
106 
107 
108 #else // IS_MINGW
109 
110 #ifdef GUI_GTK
111 #ifndef GDK_WINDOWING_X11
112 #define GDK_WINDOWING_X11
113 #endif
114 #else
115 #include <sys/types.h>
116 #include <unistd.h>
117 #endif // GUI_GTK
118 
119 typedef pid_t lives_pid_t;
120 typedef int lives_pgid_t;
121 
122 
123 #endif // IS_MINGW
124 
125 
126 
127 
128 
129 #include <sys/stat.h>
130 #include <stdlib.h>
131 #include <stdio.h>
132 #include <unistd.h>
133 #include <string.h>
134 #include <signal.h>
135 #include <assert.h>
136 #include <errno.h>
137 
138 #ifdef __cplusplus
139 #define __STDC_CONSTANT_MACROS
140 #ifdef _STDINT_H
141 #undef _STDINT_H
142 #endif
143 #endif
144 
145 #include <stdint.h>
146 #include <stdarg.h>
147 
148 
149 #ifndef ulong
150 #define ulong unsigned long
151 #endif
152 
153 
154 #define QUOTEME(x) #x
155 
156 
158 #define MAX_FILES 65535
159 
162 #ifndef PREFIX_DEFAULT
163 #ifndef IS_MINGW
164 #define PREFIX_DEFAULT "/usr"
165 #else
166 // TODO - get this from the installer
167 #define PREFIX_DEFAULT "C:\\Program Files\\LiVES"
168 #endif
169 #endif
170 
172 #ifndef PREFIX
173 #define PREFIX PREFIX_DEFAULT
174 #endif
175 
176 
177 
178 #ifndef IS_MINGW
179 #define LIVES_DIR_SEP "/"
180 #define LIVES_STATUS_FILE_NAME ".status"
181 #define LIVES_INFO_FILE_NAME ".info"
182 #define LIVES_BFILE_NAME ".smogrify"
183 #define LIVES_SMOGPLUGIN_FILE_NAME ".smogplugin"
184 #define LIVES_SMOGVAL_FILE_NAME ".smogval"
185 #define LIVES_ENC_DEBUG_FILE_NAME ".debug_out"
186 #define LIVES_DEVNULL "/dev/null"
187 
188 #define DLL_NAME "so"
189 
190 #define DOC_DIR "/share/doc/lives-"
191 
192 #define THEME_DIR "/share/lives/themes/"
193 #define PLUGIN_SCRIPTS_DIR "/share/lives/plugins/"
194 #define PLUGIN_COMPOUND_DIR "/share/lives/plugins/"
195 #define PLUGIN_EXEC_DIR "/lives/plugins/"
196 #define ICON_DIR "/share/lives/icons/"
197 #define DESKTOP_ICON_DIR "/share/icons/hicolor/48x48/apps"
198 #define DATA_DIR "/share/lives/"
199 #define LIVES_CONFIG_DIR ".lives-dir/"
200 #define LIVES_WORK_NAME "livesprojects"
201 
202 #else // IS_MINGW
203 #define LIVES_DIR_SEP "\\"
204 #define LIVES_STATUS_FILE_NAME "status"
205 #define LIVES_INFO_FILE_NAME "info"
206 #define LIVES_BFILE_NAME "smogrify"
207 #define LIVES_SMOGPLUGIN_FILE_NAME "smogplugin"
208 #define LIVES_SMOGVAL_FILE_NAME "smogval"
209 #define LIVES_ENC_DEBUG_FILE_NAME "debug_out"
210 #define LIVES_DEVNULL "NUL"
211 
212 #define DLL_NAME "dll"
213 
214 #define DOC_DIR "\\Documents/"
215 
216 #define THEME_DIR "\\Themes/"
217 #define PLUGIN_SCRIPTS_DIR "\\Plugins/"
218 #define PLUGIN_COMPOUND_DIR "\\Plugins/"
219 #define PLUGIN_EXEC_DIR "\\Plugins/"
220 #define ICON_DIR "\\Icons/"
221 #define DATA_DIR "\\Data/"
222 #define LIVES_CONFIG_DIR "\\Config/"
223 #define LIVES_WORK_NAME "livesprojects"
224 #endif
225 
226 #define LIVES_DEVICE_DIR "/dev/"
227 
228 #define LIVES_COPYRIGHT_YEARS "2002 - 2017"
229 
230 #define LIVES_WEBSITE PACKAGE_URL
231 #define LIVES_MANUAL_URL LIVES_WEBSITE "/manual/"
232 #define LIVES_MANUAL_FILENAME "LiVES_manual.html"
233 #define LIVES_AUTHOR_EMAIL "salsaman+lives@gmail.com"
234 #define LIVES_DONATE_URL "https://sourceforge.net/p/lives/donate/"
235 #define LIVES_BUG_URL PACKAGE_BUGREPORT
236 #define LIVES_FEATURE_URL "https://sourceforge.net/p/lives/feature-requests/"
237 #define LIVES_TRANSLATE_URL "https://translations.launchpad.net/lives/trunk"
238 
239 #if defined (IS_DARWIN) || defined (__FreeBSD__)
240 #ifndef off64_t
241 #define off64_t off_t
242 #endif
243 #ifndef lseek64
244 #define lseek64 lseek
245 #endif
246 #endif
247 
248 #define DEF_FILE_PERMS (S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH)
249 
250 #define WARN_FILE_SIZE 500
253 
255 #define FPS_MAX 200.
256 
257 #define MAX_FRAME_WIDTH 100000.
258 #define MAX_FRAME_HEIGHT 100000.
259 
260 #define ENABLE_DVD_GRAB
261 
262 #ifdef HAVE_MJPEGTOOLS
263 #define HAVE_YUV4MPEG
264 #endif
265 
266 #ifdef ENABLE_ORC
267 #include <orc/orc.h>
268 #endif
269 
270 #ifdef ENABLE_OIL
271 #include <liboil/liboil.h>
272 #endif
273 
274 #ifndef IS_SOLARIS
275 #define LIVES_INLINE inline
276 #else
277 #define LIVES_INLINE
278 #endif
279 
280 #include <limits.h>
281 #include <float.h>
282 
283 #ifndef PATH_MAX
284 #ifdef MAX_PATH
285 #define PATH_MAX MAX_PATH
286 #else
287 #define PATH_MAX 4096
288 #endif
289 #endif
290 
291 #ifdef __GNUC__
292 # define WARN_UNUSED __attribute__((warn_unused_result))
293 # define GNU_PURE __attribute__((pure))
294 # define GNU_CONST __attribute__((const))
295 # define GNU_MALLOC __attribute__((malloc))
296 # define GNU_ALIGN(x) __attribute__((alloc_align(x)))
297 #else
298 # define WARN_UNUSED
299 # define GNU_PURE
300 # define GNU_CONST
301 # define GNU_MALLOC
302 # define GNU_ALIGN(x)
303 #endif
304 
305 #ifdef PRODUCE_LOG
306 #define LIVES_LOG "lives.log"
307 #endif
308 
309 uint64_t lives_random(void);
310 
311 typedef struct {
312  uint16_t red;
313  uint16_t green;
314  uint16_t blue;
316 
317 typedef struct {
318  uint16_t red;
319  uint16_t green;
320  uint16_t blue;
321  uint16_t alpha;
323 
324 
325 #include "widget-helper.h"
326 
327 typedef void *(*fn_ptr)(void *ptr);
328 
329 #define ALLOW_MPV
330 #define ALLOW_PNG24
331 
334 typedef struct {
335  int value;
336  int64_t reltime;
337 } event;
338 
339 typedef struct {
340  // processing / busy dialog
341  LiVESWidget *processing;
342  LiVESWidget *progressbar;
343  LiVESWidget *label;
344  LiVESWidget *label2;
345  LiVESWidget *label3;
346  LiVESWidget *stop_button;
347  LiVESWidget *pause_button;
348  LiVESWidget *preview_button;
349  LiVESWidget *cancel_button;
350  LiVESWidget *scrolledwindow;
351  uint32_t frames_done;
352  boolean is_ready;
353 } xprocess;
354 
355 
356 
357 
358 typedef struct {
359  int afile;
360  double seek;
361  double vel;
363 
364 
365 #if HAVE_SYSTEM_WEED
366 #include <weed/weed.h>
367 #include <weed/weed-events.h>
368 #else
369 #include "../libweed/weed.h"
370 #include "../libweed/weed-events.h"
371 #endif
372 
373 // see weed event spec. for more info
374 
376 #include "events.h"
377 
378 #ifdef IS_LIBLIVES
379 #include "liblives.hpp"
380 #include "lbindings.h"
381 #endif
382 
383 typedef enum {
399 
402 
405 
407 
410 
412 } lives_undo_t;
413 
414 
416 typedef enum {
421 
422 
424 typedef enum {
427 
430 
433 
436 
439 
442 
445 
448 
451 
454 
457 
460 
463 
466 
469 
471 
472 
473 typedef enum {
477 
478 
479 
480 
481 typedef enum {
489 
490 
491 typedef enum {
496 
497 #define IMG_TYPE_BEST IMG_TYPE_PNG
498 
499 
500 #define AFORM_SIGNED 0
501 #define AFORM_LITTLE_ENDIAN 0
502 
503 #define AFORM_UNSIGNED 1
504 #define AFORM_BIG_ENDIAN (1<<1)
505 #define AFORM_UNKNOWN 65536
506 
507 
508 typedef enum {
513 
514 
515 #include "pangotext.h"
516 
517 #define WEED_LEAF_HOST_DEINTERLACE "host_deinterlace" // frame needs deinterlacing
518 #define WEED_LEAF_HOST_TC "host_tc" // timecode for deinterlace
519 #define WEED_LEAF_HOST_DECODER "host_decoder" // pointer to decoder for a layer
520 #define WEED_LEAF_HOST_PTHREAD "host_pthread" // thread for a layer
521 
523 typedef struct {
524  // basic info (saved during backup)
525  int bpp;
526  double fps;
527  int hsize;
528  int vsize;
529  int arps;
530  uint32_t signed_endian;
531 
532  int arate;
533  uint64_t unique_id;
534  int achans;
536 
538  int frames;
539  char title[256];
540  char author[256];
541  char comment[256];
542  char keywords[256];
544 
546 
547  // extended info (not saved)
549 
550 #define LIVES_CLIP_HEADER_VERSION 100
551 
553 
556 
557  char handle[256];
558  int ohsize;
559  int ovsize;
560  int64_t f_size;
561  int64_t afilesize;
563  char file_name[PATH_MAX];
564  char info_file[PATH_MAX];
565  char name[256];
566  char save_file_name[PATH_MAX];
567  char type[64];
568  int start;
569  int end;
574  boolean changed;
575  LiVESWidget *menuentry;
577  boolean orig_file_name;
578  boolean was_renamed;
579  boolean is_untitled;
580  double pb_fps;
581  double freeze_fps;
582  boolean play_paused;
583 
584  //opening/restoring status
585  boolean opening;
586  boolean opening_audio;
588  boolean opening_loc;
589  boolean restoring;
590  boolean is_loaded;
591 
593  boolean nopreview;
594 
596  boolean nokeep;
597 
598  // various times; total time is calculated as the longest of video, laudio and raudio
599  double total_time;
600  double video_time;
601  double laudio_time;
602  double raudio_time;
603  double pointer_time;
604 
605  // used only for insert_silence, holds pre-padding length for undo
608 
609  // current and last played index frames for internal player
610  int frameno;
612 
613 
614 
616  // see resample.c for new events system
617 
618 
619  // events
620  event *events[1];
621 
622  weed_plant_t *event_list;
623  weed_plant_t *event_list_back;
624  weed_plant_t *next_event;
625 
626  LiVESList *layout_map;
628 
631 
633  int undo_end;
634  char undo_text[32];
635  char redo_text[32];
636  boolean undoable;
637  boolean redoable;
638 
639  // used for storing undo values
644  uint32_t undo1_uint;
645  double undo1_dbl;
646  double undo2_dbl;
647  boolean undo1_boolean;
648  boolean undo2_boolean;
649  boolean undo3_boolean;
650 
655  int undo_arps;
656 
658 
659  void *ext_src;
660 
666 
668 
670 
671 #define FX_FRAME_PUMP_VAL 200
672 
673 #define IMG_BUFF_SIZE 4096
674 
675  boolean ratio_fps;
676 
677  int64_t aseek_pos;
678 
679  // decoder data
680 
681  char mime_type[256];
682 
683 
684  boolean deinterlace;
685 
687 
693 
695 
696  char *op_dir;
697  uint64_t op_ds_warn_level;
698 
702 
704 
705  lives_painter_surface_t *laudio_drawable;
706  lives_painter_surface_t *raudio_drawable;
707 
708  int cb_src;
709 
710  boolean needs_update;
711 } lives_clip_t;
712 
713 
714 
715 typedef struct {
716  // the following can be assumed TRUE, they are checked on startup
717  boolean has_smogrify;
723 
724  // the following may need checking before use
725  boolean has_dvgrab;
726  boolean has_sox_play;
727  boolean has_sox_sox;
728  boolean has_autolives;
729  boolean has_mplayer;
730  boolean has_mplayer2;
731  boolean has_mpv;
732  boolean has_convert;
733  boolean has_composite;
734  boolean has_identify;
735  boolean has_cdda2wav;
736  boolean has_icedax;
738  boolean has_jackd;
740  boolean has_xwininfo;
741  boolean has_gdb;
744 
746  char home_dir[PATH_MAX];
747 
748  char touch_cmd[PATH_MAX];
749  char rm_cmd[PATH_MAX];
750  char mv_cmd[PATH_MAX];
751  char cp_cmd[PATH_MAX];
752  char ln_cmd[PATH_MAX];
753  char chmod_cmd[PATH_MAX];
754  char cat_cmd[PATH_MAX];
755  char echo_cmd[PATH_MAX];
756  char eject_cmd[PATH_MAX];
757  char rmdir_cmd[PATH_MAX];
758 
759  char *rcfile;
760 
762  char startup_msg[256];
763 
764  // plugins
766 
767  boolean has_python;
768  uint64_t python_version;
769 
770  short cpu_bits;
771 
772 
773  char *myname_full;
774  char *myname;
775 
776  boolean has_stderr;
777 
779 
780  int ncpus;
781 
783 
784  pid_t mainpid;
785 
786  mode_t umask;
787 
788 } capability;
789 
790 
792 extern capability *capable;
793 
794 #ifdef HAVE_JACK_JACK_H
795 #include "jack.h"
796 #endif
797 
798 #define __STDC_FORMAT_MACROS
799 #include <inttypes.h>
800 
801 #ifndef PRId64
802 
803 #ifndef __WORDSIZE
804 #if defined __x86_64__
805 # define __WORDSIZE 64
806 #ifndef __WORDSIZE_COMPAT32
807 # define __WORDSIZE_COMPAT32 1
808 #endif
809 #else
810 # define __WORDSIZE 32
811 #endif
812 #endif // __WORDSIZE
813 
814 #ifndef __PRI64_PREFIX
815 # if __WORDSIZE == 64
816 # define __PRI64_PREFIX "l"
817 # else
818 # define __PRI64_PREFIX "ll"
819 # endif
820 #endif
821 
822 # define PRId64 __PRI64_PREFIX "d"
823 # define PRIu64 __PRI64_PREFIX "u"
824 #endif // ifndef PRI64d
825 
826 
827 // common defs for mainwindow (retain this order)
828 #include "plugins.h"
829 #include "colourspace.h"
830 #include "paramspecial.h"
831 #include "multitrack.h"
832 #include "mainwindow.h"
833 #include "keyboard.h"
834 #include "preferences.h"
835 
836 extern mainwindow *mainw;
837 
838 
839 // internal player clock
840 #include <sys/time.h>
841 struct timeval tv;
842 
843 
845 extern ssize_t sizint, sizdbl, sizshrt;
846 
847 
848 
849 typedef enum {
874 
875 
876 // some useful functions
877 
878 
879 // dialogs.c
880 boolean do_progress_dialog(boolean visible, boolean cancellable, const char *text);
881 boolean do_warning_dialog(const char *text);
882 boolean do_warning_dialog_with_check(const char *text, int warn_mask_number);
883 boolean do_warning_dialog_with_check_transient(const char *text, int warn_mask_number, LiVESWindow *transient);
884 boolean do_yesno_dialog(const char *text);
885 boolean do_yesno_dialog_with_check(const char *text, int warn_mask_number);
886 boolean do_yesno_dialog_with_check_transient(const char *text, int warn_mask_number, LiVESWindow *transient);
887 boolean do_yesno_dialog_with_check(const char *text, int warn_mask_number);
888 boolean do_yesno_dialog_with_check_transient(const char *text, int warn_mask_number, LiVESWindow *transient);
889 int do_abort_cancel_retry_dialog(const char *text, LiVESWindow *transient) WARN_UNUSED;
890 int do_error_dialog(const char *text);
891 int do_info_dialog(const char *text);
892 int do_error_dialog_with_check(const char *text, int warn_mask_number);
893 int do_blocking_error_dialog(const char *text);
894 int do_blocking_info_dialog(const char *text);
895 int do_error_dialog_with_check_transient(const char *text, boolean is_blocking, int warn_mask_number,
896  LiVESWindow *transient);
897 int do_info_dialog_with_transient(const char *text, boolean is_blocking, LiVESWindow *transient);
898 LiVESWidget *create_message_dialog(lives_dialog_t diat, const char *text, LiVESWindow *transient,
899  int warn_mask_number, boolean is_blocking);
900 
901 LiVESWidget *create_question_dialog(const char *title, const char *text, LiVESWindow *parent);
902 
903 void do_system_failed_error(const char *com, int retval, const char *addinfo);
904 int do_write_failed_error_s_with_retry(const char *fname, const char *errtext, LiVESWindow *transient) WARN_UNUSED;
905 void do_write_failed_error_s(const char *filename, const char *addinfo);
906 int do_read_failed_error_s_with_retry(const char *fname, const char *errtext, LiVESWindow *transient) WARN_UNUSED;
907 void do_read_failed_error_s(const char *filename, const char *addinfo);
908 boolean do_header_write_error(int clip);
911 void do_chdir_failed_error(const char *dir);
912 void handle_backend_errors(void);
913 boolean check_backend_return(lives_clip_t *sfile);
914 
916 char *ds_critical_msg(const char *dir, uint64_t dsval);
917 char *ds_warning_msg(const char *dir, uint64_t dsval, uint64_t cwarn, uint64_t nwarn);
918 boolean check_storage_space(lives_clip_t *sfile, boolean is_processing);
919 
920 char *get_upd_msg(int type);
921 char *get_new_install_msg(void);
922 
923 boolean ask_permission_dialog(int what);
924 boolean do_abort_check(void);
925 void add_warn_check(LiVESBox *box, int warn_mask_number);
926 void do_memory_error_dialog(void);
927 void too_many_files(void);
928 void workdir_warning(void);
929 void do_audio_import_error(void);
930 void do_mt_backup_space_error(lives_mt *, int memreq_mb);
931 
932 boolean do_clipboard_fps_warning(void);
933 void perf_mem_warning(void);
934 void do_dvgrab_error(void);
935 boolean do_comments_dialog(int fileno, char *filename);
936 boolean do_auto_dialog(const char *text, int type);
937 void do_encoder_acodec_error(void);
938 void do_encoder_sox_error(void);
939 boolean rdet_suggest_values(int width, int height, double fps, int fps_num, int fps_denom, int arate,
940  int asigned, boolean swap_endian, boolean anr, boolean ignore_fps);
941 boolean do_encoder_restrict_dialog(int width, int height, double fps, int fps_num, int fps_denom,
942  int arate, int asigned, boolean swap_endian, boolean anr, boolean save_all);
943 void do_messages_window(void);
944 void do_firstever_dialog(void);
945 void do_upgrade_error_dialog(void);
946 void do_no_mplayer_sox_error(void);
947 void do_need_mplayer_dialog(void);
948 void do_need_mplayer_mpv_dialog(void);
949 void do_aud_during_play_error(void);
950 void do_rendered_fx_dialog(void);
951 void do_layout_scrap_file_error(void);
952 void do_layout_ascrap_file_error(void);
953 void do_lb_composite_error(void);
954 void do_lb_convert_error(void);
955 void do_ra_convert_error(void);
956 void do_set_load_lmap_error(void);
957 boolean do_set_duplicate_warning(const char *new_set);
958 boolean do_set_rename_old_layouts_warning(const char *new_set);
959 boolean do_layout_alter_frames_warning(void);
960 boolean do_layout_alter_audio_warning(void);
961 boolean do_yuv4m_open_warning(void);
962 void do_mt_undo_mem_error(void);
963 void do_mt_undo_buf_error(void);
964 void do_mt_set_mem_error(boolean has_mt, boolean trans);
965 void do_mt_audchan_error(int warn_mask);
966 void do_mt_no_audchan_error(void);
967 void do_mt_no_jack_error(int warn_mask);
968 boolean do_mt_rect_prompt(void);
969 void do_audrate_error_dialog(void);
970 boolean do_event_list_warning(void);
971 void do_nojack_rec_error(void);
972 void do_vpp_palette_error(void);
973 void do_vpp_fps_error(void);
974 void do_decoder_palette_error(void);
975 void do_rmem_max_error(int size);
976 boolean do_original_lost_warning(const char *fname);
977 void do_no_decoder_error(const char *fname);
978 void do_jack_noopen_warn(void);
979 void do_jack_noopen_warn2(void);
980 void do_jack_noopen_warn3(void);
981 void do_jack_noopen_warn4(void);
982 void do_file_perm_error(const char *file_name);
983 void do_dir_perm_error(const char *dir_name);
984 void do_dir_perm_access_error(const char *dir_name);
986 void do_after_crash_warning(void);
987 void do_bad_layout_error(void);
988 void do_card_in_use_error(void);
989 void do_dev_busy_error(const char *devstr);
990 boolean do_existing_subs_warning(void);
991 void do_invalid_subs_error(void);
992 boolean do_erase_subs_warning(void);
993 boolean do_sub_type_warning(const char *ext, const char *type_ext);
994 boolean do_move_workdir_dialog(void);
995 void do_set_locked_warning(const char *setname);
996 void do_no_in_vdevs_error(void);
997 void do_locked_in_vdevs_error(void);
998 void do_do_not_close_d(void);
999 void do_set_noclips_error(const char *setname);
1000 void do_no_autolives_error(void);
1002 void do_pulse_lost_conn_error(void);
1003 void do_jack_lost_conn_error(void);
1004 void do_cd_error_dialog(void);
1005 void do_bad_theme_error(const char *themefile);
1006 void do_bad_theme_import_error(const char *theme_file);
1007 boolean do_theme_exists_warn(const char *themename);
1008 
1009 boolean process_one(boolean visible);
1010 void do_threaded_dialog(char *translated_text, boolean has_cancel);
1011 void end_threaded_dialog(void);
1012 void threaded_dialog_spin(double fraction);
1013 void response_ok(LiVESButton *button, livespointer user_data);
1014 void pump_io_chan(LiVESIOChannel *iochan);
1015 
1016 void do_splash_progress(void);
1017 
1018 
1019 // d_print shortcuts
1020 void d_print_cancelled(void);
1021 void d_print_failed(void);
1022 void d_print_done(void);
1023 void d_print_file_error_failed(void);
1024 
1025 // general
1026 void do_text_window(const char *title, const char *text);
1027 
1028 // saveplay.c
1029 boolean read_file_details(const char *file_name, boolean only_check_for_audio);
1030 boolean add_file_info(const char *check_handle, boolean aud_only);
1031 boolean save_file_comments(int fileno);
1032 boolean reload_clip(int fileno,int maxframe);
1034 void reget_afilesize(int fileno);
1035 ulong deduce_file(const char *filename, double start_time, int end);
1036 ulong open_file(const char *filename);
1037 ulong open_file_sel(const char *file_name, double start_time, int frames);
1038 void open_fw_device(void);
1039 boolean get_new_handle(int index, const char *name);
1040 boolean get_temp_handle(int index, boolean create);
1041 boolean get_handle_from_info_file(int index);
1042 void create_cfile(void);
1043 void save_file(int clip, int start, int end, const char *filename);
1044 void play_file(void);
1045 void save_frame(LiVESMenuItem *menuitem, livespointer user_data);
1046 boolean save_frame_inner(int clip, int frame, const char *file_name, int width, int height, boolean from_osc);
1047 void wait_for_stop(const char *stop_command);
1048 boolean save_clip_values(int which_file);
1049 void add_to_recovery_file(const char *handle);
1050 void rewrite_recovery_file(void);
1051 boolean check_for_recovery_files(boolean auto_recover);
1052 void recover_layout_map(int numclips);
1053 const char *get_deinterlace_string(void);
1054 
1055 // saveplay.c backup
1056 void backup_file(int clip, int start, int end, const char *filename);
1057 int save_event_frames(void);
1058 boolean write_headers(lives_clip_t *file);
1059 
1060 // saveplay.c restore
1061 ulong restore_file(const char *filename);
1062 boolean read_headers(const char *file_name);
1063 
1064 // saveplay.c sets
1065 void open_set_file(const char *set_name, int clipnum);
1066 
1067 
1068 // saveplay.c scrap file
1069 boolean open_scrap_file(void);
1070 boolean open_ascrap_file(void);
1071 int save_to_scrap_file(weed_plant_t *layer);
1072 boolean load_from_scrap_file(weed_plant_t *layer, int frame);
1073 void close_ascrap_file(void);
1074 void close_scrap_file(void);
1075 void add_to_ascrap_mb(uint64_t bytes);
1076 
1077 boolean check_for_disk_space(void);
1078 
1079 
1080 // main.c
1081 typedef void (*SignalHandlerPointer)(int);
1082 
1084 void catch_sigint(int signum);
1085 void defer_sigint(int signum);
1086 boolean startup_message_fatal(const char *msg);
1087 boolean startup_message_choice(const char *msg, int msgtype);
1088 boolean startup_message_nonfatal(const char *msg);
1089 boolean startup_message_info(const char *msg);
1090 boolean startup_message_nonfatal_dismissable(const char *msg, int warning_mask);
1092 void get_monitors(void);
1093 void set_ce_frame_from_pixbuf(LiVESImage *image, LiVESPixbuf *pixbuf, lives_painter_t *);
1094 void load_start_image(int frame);
1095 void load_end_image(int frame);
1096 void load_preview_image(boolean update_always);
1097 
1098 boolean pull_frame(weed_plant_t *layer, const char *image_ext, weed_timecode_t tc);
1099 void pull_frame_threaded(weed_plant_t *layer, const char *img_ext, weed_timecode_t tc);
1100 void check_layer_ready(weed_plant_t *layer);
1101 boolean pull_frame_at_size(weed_plant_t *layer, const char *image_ext, weed_timecode_t tc,
1102  int width, int height, int target_palette);
1103 LiVESPixbuf *pull_lives_pixbuf_at_size(int clip, int frame, const char *image_ext, weed_timecode_t tc,
1104  int width, int height, LiVESInterpType interp);
1105 LiVESPixbuf *pull_lives_pixbuf(int clip, int frame, const char *image_ext, weed_timecode_t tc);
1106 
1107 LiVESError *lives_pixbuf_save(LiVESPixbuf *pixbuf, char *fname, lives_image_type_t imgtype,
1108  int quality, boolean do_chmod, LiVESError **gerrorptr);
1109 
1110 void init_track_decoders(void);
1111 void free_track_decoders(void);
1112 
1113 #ifdef USE_LIBPNG
1114 boolean layer_from_png(FILE *fp, weed_plant_t *layer, boolean prog);
1115 boolean save_to_png(FILE *fp, weed_plant_t *layer, int comp);
1116 #endif
1117 
1118 void load_frame_image(int frame);
1119 void sensitize(void);
1120 void desensitize(void);
1121 void procw_desensitize(void);
1122 void close_current_file(int file_to_switch_to);
1123 void get_next_free_file(void);
1124 void switch_to_file(int old_file, int new_file);
1125 void do_quick_switch(int new_file);
1126 void switch_audio_clip(int new_file, boolean activate);
1127 void resize(double scale);
1128 void do_start_messages(void);
1129 boolean set_palette_colours(boolean force_reload);
1130 void set_main_title(const char *filename, int or_untitled_number);
1131 void set_record(void);
1132 
1133 //gui.c
1134 void create_LiVES(void);
1135 void show_lives(void);
1136 void set_colours(LiVESWidgetColor *colf, LiVESWidgetColor *colb, LiVESWidgetColor *colf2,
1137  LiVESWidgetColor *colb2, LiVESWidgetColor *coli, LiVESWidgetColor *colt);
1138 void set_preview_box_colours(void);
1139 void load_theme_images(void);
1140 void set_interactive(boolean interactive);
1141 char *get_menu_name(lives_clip_t *sfile);
1142 void enable_record(void);
1143 void toggle_record(void);
1144 void disable_record(void);
1145 void make_custom_submenus(void);
1146 void fade_background(void);
1147 void unfade_background(void);
1148 void block_expose(void);
1149 void unblock_expose(void);
1150 void frame_size_update(void);
1151 void splash_init(void);
1152 void splash_end(void);
1153 void splash_msg(const char *msg, double pct);
1154 void add_message_scroller(LiVESWidget *conter);
1156 #if GTK_CHECK_VERSION(3,0,0)
1157 void calibrate_sepwin_size(void);
1158 boolean expose_pim(LiVESWidget *widget, lives_painter_t *cr, livespointer user_data);
1159 boolean expose_sim(LiVESWidget *widget, lives_painter_t *cr, livespointer user_data);
1160 boolean expose_eim(LiVESWidget *widget, lives_painter_t *cr, livespointer user_data);
1161 #endif
1162 
1163 
1164 
1165 
1166 
1167 // system calls in utils.c
1168 int lives_system(const char *com, boolean allow_error);
1169 lives_pid_t lives_fork(const char *com);
1170 int lives_open3(const char *pathname, int flags, mode_t mode);
1171 int lives_open2(const char *pathname, int flags);
1172 int lives_open_buffered_rdonly(const char *pathname);
1173 int lives_creat_buffered(const char *pathname, int mode);
1174 int lives_close_buffered(int fd);
1175 void lives_close_all_file_buffers(void);
1176 off_t lives_lseek_buffered_rdonly(int fd, off_t offset);
1177 ssize_t lives_write(int fd, livesconstpointer buf, size_t count, boolean allow_fail);
1178 ssize_t lives_write_buffered(int fd, const char *buf, size_t count, boolean allow_fail);
1179 ssize_t lives_write_le(int fd, livesconstpointer buf, size_t count, boolean allow_fail);
1180 ssize_t lives_write_le_buffered(int fd, livesconstpointer buf, size_t count, boolean allow_fail);
1181 ssize_t lives_read(int fd, void *buf, size_t count, boolean allow_less);
1182 ssize_t lives_read_buffered(int fd, void *buf, size_t count, boolean allow_less);
1183 ssize_t lives_read_le(int fd, void *buf, size_t count, boolean allow_less);
1184 ssize_t lives_read_le_buffered(int fd, void *buf, size_t count, boolean allow_less);
1185 int lives_chdir(const char *path, boolean allow_fail);
1186 int lives_fputs(const char *s, FILE *stream);
1187 char *lives_fgets(char *s, int size, FILE *stream);
1188 pid_t lives_getpid(void);
1189 int lives_getgid(void);
1190 int lives_getuid(void);
1191 boolean lives_freep(void **ptr);
1192 void lives_kill_subprocesses(const char *dirname, boolean kill_parent);
1193 void lives_suspend_resume_process(const char *dirname, boolean suspend);
1194 #ifdef IS_MINGW
1195 boolean lives_win32_suspend_resume_process(DWORD pid, boolean suspend);
1196 boolean lives_win32_kill_subprocesses(DWORD pid, boolean kill_parent);
1197 int lives_win32_get_num_logical_cpus(void);
1198 #endif
1199 int lives_kill(lives_pid_t pid, int sig);
1200 int lives_killpg(lives_pgid_t pgrp, int sig);
1201 void lives_srandom(unsigned int seed);
1202 ssize_t lives_readlink(const char *path, char *buf, size_t bufsiz);
1203 boolean lives_setenv(const char *name, const char *value);
1204 boolean lives_fsync(int fd);
1205 void lives_sync(void);
1206 int lives_rmdir(const char *dir, boolean force);
1207 int lives_rmdir_with_parents(const char *dir);
1208 int lives_rm(const char *file);
1209 int lives_rmglob(const char *files);
1210 int lives_cp(const char *from, const char *to);
1211 int lives_cp_keep_perms(const char *from, const char *to);
1212 int lives_mv(const char *from, const char *to);
1213 int lives_touch(const char *tfile);
1214 int lives_chmod(const char *target, const char *mode);
1215 int lives_cat(const char *from, const char *to, boolean append);
1216 int lives_echo(const char *text, const char *to, boolean append);
1217 int lives_ln(const char *from, const char *to);
1218 
1219 
1220 int lives_utf8_strcasecmp(const char *s1, const char *s2);
1221 
1222 char *filename_from_fd(char *val, int fd);
1223 
1224 float LEFloat_to_BEFloat(float f) GNU_CONST;
1225 uint64_t lives_10pow(int pow) GNU_CONST;
1226 double lives_fix(double val, int decimals) GNU_CONST;
1227 int get_approx_ln(uint32_t val) GNU_CONST;
1228 
1229 int64_t lives_get_current_ticks(void);
1230 boolean lives_alarm_get(int alarm_handle);
1231 int lives_alarm_set(int64_t ticks);
1232 void lives_alarm_clear(int alarm_handle);
1233 lives_storage_status_t get_storage_status(const char *dir, uint64_t warn_level, uint64_t *dsval);
1234 char *lives_format_storage_space_string(uint64_t space);
1235 
1236 
1237 int myround(double n);
1238 void get_dirname(char *filename);
1239 char *get_dir(const char *filename);
1240 void get_basename(char *filename);
1241 void get_filename(char *filename, boolean strip_dir);
1242 char *get_extension(const char *filename);
1243 uint64_t get_version_hash(const char *exe, const char *sep, int piece);
1244 uint64_t make_version_hash(const char *ver);
1245 void d_print(const char *fmt, ...);
1246 void init_clipboard(void);
1247 boolean cache_file_contents(const char *filename);
1248 char *get_val_from_cached_list(const char *key, size_t maxlen);
1249 
1250 void get_location(const char *exe, char *val, int maxlen);
1251 
1252 char *make_image_file_name(lives_clip_t *clip, int frame, const char *img_ext);
1253 const char *get_image_ext_for_type(lives_image_type_t imgtype);
1254 lives_image_type_t lives_image_ext_to_type(const char *img_ext);
1255 lives_image_type_t lives_image_type_to_image_type(const char *lives_img_type);
1256 
1257 void set_menu_text(LiVESWidget *menu, const char *text, boolean use_mnemonic);
1258 void get_menu_text(LiVESWidget *menu, char *text);
1259 void get_menu_text_long(LiVESWidget *menuitem, char *text);
1260 void reset_clipmenu(void);
1261 void get_play_times(void);
1262 void get_total_time(lives_clip_t *file);
1263 uint32_t get_signed_endian(boolean is_signed, boolean little_endian);
1264 void fullscreen_internal(void);
1265 void switch_to_int_player(void);
1266 void switch_to_mplayer(void);
1267 void switch_aud_to_sox(boolean set_pref);
1268 boolean switch_aud_to_jack(void);
1269 boolean switch_aud_to_pulse(void);
1270 void switch_aud_to_mplayer(boolean set_pref);
1271 void switch_aud_to_mplayer2(boolean set_pref);
1272 boolean prepare_to_play_foreign(void);
1273 boolean after_foreign_play(void);
1274 boolean check_file(const char *file_name, boolean check_exists);
1275 boolean check_dir_access(const char *dir);
1276 uint64_t get_file_size(int fd);
1277 uint64_t sget_file_size(const char *name);
1278 uint64_t get_fs_free(const char *dir);
1279 boolean is_writeable_dir(const char *dir);
1280 boolean ensure_isdir(char *fname);
1281 char *ensure_extension(const char *fname, const char *ext) WARN_UNUSED;
1282 boolean check_dev_busy(char *devstr);
1283 void activate_url_inner(const char *link);
1284 void activate_url(LiVESAboutDialog *about, const char *link, livespointer data);
1285 void show_manual_section(const char *lang, const char *section);
1286 
1287 double calc_time_from_frame(int clip, int frame);
1288 int calc_frame_from_time(int filenum, double time);
1289 int calc_frame_from_time2(int filenum, double time);
1290 int calc_frame_from_time3(int filenum, double time);
1291 
1292 boolean check_for_ratio_fps(double fps);
1293 double get_ratio_fps(const char *string);
1294 void calc_maxspect(int rwidth, int rheight, int *cwidth, int *cheight);
1295 
1296 char *remove_trailing_zeroes(double val);
1297 
1298 void remove_layout_files(LiVESList *lmap);
1299 boolean add_lmap_error(lives_lmap_error_t lerror, const char *name, livespointer user_data,
1300  int clipno, int frameno, double atime, boolean affects_current);
1301 void clear_lmap_errors(void);
1302 boolean prompt_remove_layout_files(void);
1303 boolean do_std_checks(const char *type_name, const char *type, size_t maxlen, const char *nreject);
1304 boolean is_legal_set_name(const char *set_name, boolean allow_dupes);
1305 char *repl_workdir(const char *entry, boolean fwd);
1306 char *clip_detail_to_string(lives_clip_details_t what, size_t *maxlenp);
1307 boolean get_clip_value(int which, lives_clip_details_t, void *retval, size_t maxlen);
1308 void save_clip_value(int which, lives_clip_details_t, void *val);
1309 boolean check_frame_count(int idx);
1310 void count_opening_frames(void);
1311 void get_frame_count(int idx);
1312 void get_frames_sizes(int fileno, int frame_to_test);
1313 int count_resampled_frames(int in_frames, double orig_fps, double resampled_fps);
1314 boolean int_array_contains_value(int *array, int num_elems, int value);
1315 boolean check_for_lock_file(const char *set_name, int type);
1316 void lives_list_free_strings(LiVESList *);
1317 void lives_list_free_all(LiVESList **);
1318 void lives_slist_free_all(LiVESSList **);
1319 
1320 boolean create_event_space(int length_in_eventsb);
1321 void add_to_recent(const char *filename, double start, int frames, const char *file_open_params);
1322 int verhash(char *version);
1323 void set_undoable(const char *what, boolean sensitive);
1324 void set_redoable(const char *what, boolean sensitive);
1325 void zero_spinbuttons(void);
1326 void draw_little_bars(double ptrtime);
1327 void set_sel_label(LiVESWidget *label);
1328 void clear_mainw_msg(void);
1329 int get_token_count(const char *string, int delim);
1330 LiVESPixbuf *lives_pixbuf_new_blank(int width, int height, int palette);
1331 char *lives_strappend(char *string, int len, const char *newbit);
1332 LiVESList *lives_list_append_unique(LiVESList *xlist, const char *add);
1333 void find_when_to_stop(void);
1334 int calc_new_playback_position(int fileno, uint64_t otc, uint64_t *ntc);
1335 void calc_aframeno(int fileno);
1336 void minimise_aspect_delta(double allowed_aspect,int hblock,int vblock,int hsize,int vsize,int *width,int *height);
1337 LiVESInterpType get_interp_value(short quality);
1338 
1339 LiVESList *lives_list_move_to_first(LiVESList *list, LiVESList *item) WARN_UNUSED;
1340 LiVESList *lives_list_delete_string(LiVESList *, char *string) WARN_UNUSED;
1341 LiVESList *lives_list_copy_strings(LiVESList *list);
1342 boolean string_lists_differ(LiVESList *, LiVESList *);
1343 
1344 boolean is_realtime_aplayer(int ptype);
1345 
1346 LiVESList *get_set_list(const char *dir, boolean utf8);
1347 
1348 char *subst(const char *string, const char *from, const char *to);
1349 char *insert_newlines(const char *text, int maxwidth);
1350 
1351 int hextodec(char *string);
1352 int get_hex_digit(const char *c);
1353 
1354 uint32_t fastrand(void);
1355 void fastsrand(uint32_t seed);
1356 
1357 int lives_list_strcmp_index(LiVESList *list, livesconstpointer data);
1358 
1360 
1361 //callbacks.c
1362 
1363 
1364 // paramspecial.c
1365 LiVESPixbuf *mt_framedraw(lives_mt *, LiVESPixbuf *);
1366 
1367 
1368 // effects-weed.c
1369 livespointer _lives_malloc(size_t size) GNU_MALLOC;
1370 livespointer lives_memcpy(livespointer dest, livesconstpointer src, size_t n);
1371 livespointer lives_memset(livespointer s, int c, size_t n);
1372 void _lives_free(livespointer ptr);
1373 livespointer lives_calloc(size_t n_blocks, size_t n_block_bytes);
1374 livespointer _lives_realloc(livespointer ptr, size_t new_size);
1375 
1376 
1377 // pangotext.c
1378 boolean subtitles_init(lives_clip_t *sfile, char *fname, lives_subtitle_type_t);
1379 void subtitles_free(lives_clip_t *sfile);
1380 boolean get_srt_text(lives_clip_t *sfile, double xtime);
1381 boolean get_sub_text(lives_clip_t *sfile, double xtime);
1382 boolean save_sub_subtitles(lives_clip_t *sfile, double start_time, double end_time, double offset_time, const char *filename);
1383 boolean save_srt_subtitles(lives_clip_t *sfile, double start_time, double end_time, double offset_time, const char *filename);
1384 
1385 #include "osc_notify.h"
1386 
1387 // inlines
1388 #define cfile mainw->files[mainw->current_file]
1389 #define clipboard mainw->files[0]
1390 
1391 #define PREFS_TIMEOUT 10000000
1392 
1393 #define LIVES_TV_CHANNEL1 "http://www.serverwillprovide.com/sorteal/livestvclips/livestv.ogm"
1394 
1395 
1396 // round (double) a up to next (integer) multiple of (double) b
1397 #define CEIL(a,b) ((int)(((double)a+(double)b-.000000001)/((double)b))*b)
1398 
1399 #ifdef NEED_ENDIAN_TEST
1400 #undef NEED_ENDIAN_TEST
1401 static int32_t testint = 0x12345678;
1402 #define IS_BIG_ENDIAN (((char *)&testint)[0] == 0x12)
1403 #endif
1404 
1405 
1407 
1408 void break_me(void);
1409 
1410 #define LIVES_NO_DEBUG
1411 #ifndef LIVES_DEBUG
1412 #ifndef LIVES_NO_DEBUG
1413 #define LIVES_DEBUG(x) fprintf(stderr, "LiVES debug: %s\n", x)
1414 #else // LIVES_NO_DEBUG
1415 #define LIVES_DEBUG(x) dummychar = x
1416 #endif // LIVES_NO_DEBUG
1417 #endif // LIVES_DEBUG
1418 
1419 #ifndef LIVES_INFO
1420 #ifndef LIVES_NO_INFO
1421 #define LIVES_INFO(x) fprintf(stderr, "LiVES info: %s\n", x)
1422 #else // LIVES_NO_INFO
1423 #define LIVES_INFO(x) dummychar = x
1424 #endif // LIVES_NO_INFO
1425 #endif // LIVES_INFO
1426 
1427 #ifndef LIVES_WARN
1428 #ifndef LIVES_NO_WARN
1429 #define LIVES_WARN(x) fprintf(stderr, "LiVES warning: %s\n", x)
1430 #else // LIVES_NO_WARN
1431 #define LIVES_WARN(x) dummychar = x
1432 #endif // LIVES_NO_WARN
1433 #endif // LIVES_WARN
1434 
1435 #ifndef LIVES_ERROR
1436 #ifndef LIVES_NO_ERROR
1437 #define LIVES_ERROR(x) {fprintf(stderr, "LiVES error: %s\n", x); break_me();}
1438 #else // LIVES_NO_ERROR
1439 #define LIVES_ERROR(x) dummychar = x
1440 #endif // LIVES_NO_ERROR
1441 #endif // LIVES_ERROR
1442 
1443 #ifndef LIVES_FATAL
1444 #ifndef LIVES_NO_FATAL
1445 #define LIVES_FATAL(x) {fprintf(stderr, "LiVES fatal: %s\n", x); raise (LIVES_SIGSEGV);}
1446 #else // LIVES_NO_FATAL
1447 #define LIVES_FATAL(x) dummychar = x
1448 #endif // LIVES_NO_FATAL
1449 #endif // LIVES_FATAL
1450 
1451 
1452 #endif // #ifndef HAS_LIVES_MAIN_H
1453 
void do_messages_window(void)
Definition: dialogs.c:2529
void do_ra_convert_error(void)
Definition: dialogs.c:2748
int lives_touch(const char *tfile)
Definition: utils.c:3985
int undo_arate
audio playback rate
Definition: main.h:651
boolean do_warning_dialog_with_check_transient(const char *text, int warn_mask_number, LiVESWindow *transient)
Definition: dialogs.c:401
void load_theme_images(void)
Definition: gui.c:58
void do_encoder_sox_error(void)
Definition: dialogs.c:2231
void handle_backend_errors(void)
Definition: dialogs.c:694
int frames
Definition: main.h:538
LiVESPixbuf * pull_lives_pixbuf_at_size(int clip, int frame, const char *image_ext, weed_timecode_t tc, int width, int height, LiVESInterpType interp)
Definition: main.c:5261
double undo2_dbl
Definition: main.h:646
int afile
Definition: main.h:359
void reget_afilesize(int fileno)
Definition: utils.c:4250
char * ensure_extension(const char *fname, const char *ext) WARN_UNUSED
Definition: utils.c:2470
boolean do_yesno_dialog_with_check(const char *text, int warn_mask_number)
Definition: dialogs.c:388
boolean has_stderr
Definition: main.h:776
LiVESWidget * stop_button
Definition: main.h:346
int undo1_int
Definition: main.h:640
boolean no_proc_sys_errors
skip system error dialogs in processing
Definition: main.h:699
int value
Definition: main.h:335
uint64_t python_version
Definition: main.h:768
int get_hex_digit(const char *c)
Definition: utils.c:5258
Definition: main.h:864
boolean deinterlace
auto deinterlace
Definition: main.h:684
boolean opening_audio
Definition: main.h:586
int lives_open_buffered_rdonly(const char *pathname)
Definition: utils.c:582
ulong open_file_sel(const char *file_name, double start_time, int frames)
Definition: saveplay.c:272
int undo2_int
Definition: main.h:641
Definition: main.h:388
Definition: main.h:862
double old_raudio_time
Definition: main.h:607
int verhash(char *version)
Definition: utils.c:4414
void do_mt_audchan_error(int warn_mask)
Definition: dialogs.c:2709
boolean startup_message_fatal(const char *msg)
Definition: main.c:3442
boolean pull_frame_at_size(weed_plant_t *layer, const char *image_ext, weed_timecode_t tc, int width, int height, int target_palette)
Definition: main.c:4920
void perf_mem_warning(void)
Definition: dialogs.c:2447
boolean restoring
Definition: main.h:589
void do_read_failed_error_s(const char *filename, const char *addinfo)
Definition: dialogs.c:3113
void draw_little_bars(double ptrtime)
Definition: utils.c:3006
int * frame_index_back
for undo
Definition: main.h:667
int lives_system(const char *com, boolean allow_error)
Definition: utils.c:304
void do_dir_perm_error(const char *dir_name)
Definition: dialogs.c:3308
boolean has_pulse_audio
Definition: main.h:739
boolean get_handle_from_info_file(int index)
Definition: saveplay.c:1061
int hextodec(char *string)
Definition: utils.c:5243
Definition: main.h:859
LiVESWidget * create_message_dialog(lives_dialog_t diat, const char *text, LiVESWindow *transient, int warn_mask_number, boolean is_blocking)
Definition: dialogs.c:168
double seek
Definition: main.h:360
uint32_t undo1_uint
Definition: main.h:644
ssize_t lives_read_le(int fd, void *buf, size_t count, boolean allow_less)
Definition: utils.c:528
boolean has_mpv
Definition: main.h:731
Definition: events.h:173
boolean do_move_workdir_dialog(void)
Definition: dialogs.c:3398
void _lives_free(livespointer ptr)
Definition: effects-weed.c:111
LiVESError * lives_pixbuf_save(LiVESPixbuf *pixbuf, char *fname, lives_image_type_t imgtype, int quality, boolean do_chmod, LiVESError **gerrorptr)
Definition: main.c:6697
boolean do_event_list_warning(void)
Definition: dialogs.c:2758
int start
Definition: main.h:568
int do_header_missing_detail_error(int clip, lives_clip_details_t detail) WARN_UNUSED
Definition: dialogs.c:3257
int do_error_dialog(const char *text)
Definition: dialogs.c:521
#define PATH_MAX
Definition: main.h:287
void set_main_title(const char *filename, int or_untitled_number)
Definition: main.c:3487
boolean nokeep
don&#39;t show the &#39;keep&#39; button - e.g. for operations which resize frames
Definition: main.h:596
boolean nopreview
don&#39;t show preview/pause buttons on processing
Definition: main.h:593
lives_pid_t lives_fork(const char *com)
Definition: utils.c:349
uint64_t get_fs_free(const char *dir)
Definition: utils.c:5321
pid_t lives_pid_t
Definition: main.h:119
boolean load_from_scrap_file(weed_plant_t *layer, int frame)
Definition: saveplay.c:4739
lives_dialog_t
Definition: mainwindow.h:187
void get_play_times(void)
Definition: utils.c:2706
just cancel in GUI (for keep, etc)
Definition: main.h:475
void save_frame(LiVESMenuItem *menuitem, livespointer user_data)
Definition: saveplay.c:1120
int lives_utf8_strcasecmp(const char *s1, const char *s2)
Definition: utils.c:5121
void splash_end(void)
Definition: gui.c:4369
lives_image_type_t lives_image_ext_to_type(const char *img_ext)
Definition: utils.c:2278
void find_when_to_stop(void)
Definition: utils.c:3178
void save_clip_value(int which, lives_clip_details_t, void *val)
Definition: utils.c:4840
void clear_lmap_errors(void)
Definition: utils.c:2091
void set_pref(const char *key, const char *value)
Definition: preferences.c:303
void activate_url(LiVESAboutDialog *about, const char *link, livespointer data)
Definition: utils.c:4190
void do_file_perm_error(const char *file_name)
Definition: dialogs.c:3300
int lives_rm(const char *file)
Definition: utils.c:3926
boolean is_legal_set_name(const char *set_name, boolean allow_dupes)
Definition: utils.c:2227
void do_set_load_lmap_error(void)
uint64_t lives_random(void)
Definition: utils.c:106
boolean has_mplayer
Definition: main.h:729
LiVESWidget * scrolledwindow
Definition: main.h:350
livespointer lives_memcpy(livespointer dest, livesconstpointer src, size_t n)
Definition: effects-weed.c:78
boolean do_existing_subs_warning(void)
Definition: dialogs.c:3354
video playback completed
Definition: main.h:459
int lives_pgid_t
Definition: main.h:120
boolean create_event_space(int length_in_eventsb)
Definition: utils.c:4286
void do_bad_theme_import_error(const char *theme_file)
Definition: dialogs.c:3485
void close_current_file(int file_to_switch_to)
close current file, and try to switch to file_to_switch_to
Definition: main.c:6733
void recover_layout_map(int numclips)
Definition: saveplay.c:5112
int lives_echo(const char *text, const char *to, boolean append)
Definition: utils.c:4035
Definition: main.h:391
int ohsize
Definition: main.h:558
boolean was_renamed
Definition: main.h:578
lives_painter_surface_t * raudio_drawable
Definition: main.h:706
void open_fw_device(void)
boolean reload_clip(int fileno, int maxframe)
Definition: saveplay.c:5192
char * remove_trailing_zeroes(double val)
Definition: utils.c:5069
void do_autolives_needs_clips_error(void)
Definition: dialogs.c:3467
void defer_sigint(int signum)
Definition: main.c:184
void check_layer_ready(weed_plant_t *layer)
Definition: main.c:5175
Definition: main.h:860
void workdir_warning(void)
Definition: dialogs.c:2191
Definition: main.h:863
boolean switch_aud_to_pulse(void)
Definition: utils.c:3334
boolean opening
Definition: main.h:585
int last_frameno
Definition: main.h:611
void get_basename(char *filename)
Definition: utils.c:2437
void clear_mainw_msg(void)
Definition: utils.c:1269
boolean read_headers(const char *file_name)
Definition: saveplay.c:3960
void unblock_expose(void)
Definition: gui.c:3316
boolean has_cdda2wav
Definition: main.h:735
void fastsrand(uint32_t seed)
Definition: utils.c:5279
void pull_frame_threaded(weed_plant_t *layer, const char *img_ext, weed_timecode_t tc)
Definition: main.c:5233
int do_error_dialog_with_check_transient(const char *text, boolean is_blocking, int warn_mask_number, LiVESWindow *transient)
Definition: dialogs.c:600
void d_print(const char *fmt,...)
Definition: utils.c:1862
boolean can_write_to_config
Definition: main.h:720
imported video, broken into frames
Definition: main.h:482
int progress_start
Definition: main.h:572
void frame_size_update(void)
Definition: gui.c:4154
void d_print_file_error_failed(void)
Definition: dialogs.c:3006
ssize_t sizdbl
Definition: main.c:90
lives_image_type_t
Definition: main.h:491
boolean redoable
Definition: main.h:637
LiVESList * lives_list_move_to_first(LiVESList *list, LiVESList *item) WARN_UNUSED
Definition: utils.c:5372
void do_text_window(const char *title, const char *text)
Definition: dialogs.c:2536
lives_clip_type_t clip_type
Definition: main.h:657
void do_splash_progress(void)
lives_undo_t undo_action
undo
Definition: main.h:630
Definition: main.h:492
char * get_val_from_cached_list(const char *key, size_t maxlen)
Definition: utils.c:4586
lives_subtitles_t * subt
Definition: main.h:694
livespointer _lives_malloc(size_t size) GNU_MALLOC
Definition: effects-weed.c:84
void(* SignalHandlerPointer)(int)
Definition: main.h:1081
int get_token_count(const char *string, int delim)
Definition: utils.c:5107
double total_time
Definition: main.h:599
Definition: main.h:384
void do_jack_lost_conn_error(void)
Definition: dialogs.c:3471
uint64_t sget_file_size(const char *name)
Definition: utils.c:4218
boolean has_dvgrab
Definition: main.h:725
boolean do_auto_dialog(const char *text, int type)
Definition: dialogs.c:2059
void reset_clipmenu(void)
Definition: utils.c:3820
void enable_record(void)
Definition: gui.c:3586
void do_threaded_dialog(char *translated_text, boolean has_cancel)
Definition: dialogs.c:2934
char * op_dir
Definition: main.h:696
void count_opening_frames(void)
Definition: utils.c:2330
uint16_t red
Definition: main.h:318
Definition: main.h:334
ssize_t lives_read_buffered(int fd, void *buf, size_t count, boolean allow_less)
Definition: utils.c:682
boolean do_layout_alter_frames_warning(void)
Definition: dialogs.c:2605
ulong restore_file(const char *filename)
Definition: saveplay.c:4405
lives_whentostop_t
which stream end should cause playback to finish ?
Definition: main.h:416
boolean rdet_suggest_values(int width, int height, double fps, int fps_num, int fps_denom, int arate, int asigned, boolean swap_endian, boolean anr, boolean ignore_fps)
Definition: dialogs.c:2255
void d_print_failed(void)
Definition: dialogs.c:2997
void minimise_aspect_delta(double allowed_aspect, int hblock, int vblock, int hsize, int vsize, int *width, int *height)
Definition: utils.c:3204
boolean undo1_boolean
Definition: main.h:647
void add_message_scroller(LiVESWidget *conter)
Definition: gui.c:118
boolean do_clipboard_fps_warning(void)
Definition: dialogs.c:2452
void set_sel_label(LiVESWidget *label)
Definition: utils.c:4512
char * lives_fgets(char *s, int size, FILE *stream)
Definition: utils.c:447
ssize_t lives_write_le(int fd, livesconstpointer buf, size_t count, boolean allow_fail)
ssize_t sizint
type sizes
Definition: main.c:90
boolean lives_setenv(const char *name, const char *value)
Definition: utils.c:281
boolean check_storage_space(lives_clip_t *sfile, boolean is_processing)
Definition: dialogs.c:842
Definition: main.h:317
mode_t umask
Definition: main.h:786
int ovsize
Definition: main.h:559
#define GNU_MALLOC
Definition: main.h:301
void do_vpp_fps_error(void)
Definition: dialogs.c:2784
boolean startup_message_nonfatal(const char *msg)
Definition: main.c:3450
void pump_io_chan(LiVESIOChannel *iochan)
Definition: dialogs.c:776
void do_mt_undo_buf_error(void)
Definition: dialogs.c:2689
no cancel
Definition: main.h:426
int do_read_failed_error_s_with_retry(const char *fname, const char *errtext, LiVESWindow *transient) WARN_UNUSED
Definition: dialogs.c:3192
int asampsize
Definition: main.h:535
ssize_t lives_write_buffered(int fd, const char *buf, size_t count, boolean allow_fail)
Definition: utils.c:746
LiVESList * get_set_list(const char *dir, boolean utf8)
Definition: utils.c:4971
void close_scrap_file(void)
Definition: saveplay.c:5071
boolean do_yesno_dialog_with_check_transient(const char *text, int warn_mask_number, LiVESWindow *transient)
Definition: dialogs.c:427
uint32_t undo_signed_endian
Definition: main.h:652
boolean lives_freep(void **ptr)
Definition: utils.c:873
void set_undoable(const char *what, boolean sensitive)
Definition: utils.c:4457
boolean get_temp_handle(int index, boolean create)
Definition: saveplay.c:3197
boolean get_sub_text(lives_clip_t *sfile, double xtime)
Definition: pangotext.c:566
boolean is_untitled
Definition: main.h:579
void get_next_free_file(void)
Definition: utils.c:2401
void do_firstever_dialog(void)
unimported video, not or partially broken in frames
Definition: main.h:485
int count_resampled_frames(int in_frames, double orig_fps, double resampled_fps)
Definition: resample.c:58
int lives_ln(const char *from, const char *to)
Definition: utils.c:3994
int lives_mv(const char *from, const char *to)
Definition: utils.c:3976
void end_threaded_dialog(void)
Definition: dialogs.c:2964
Definition: main.h:854
int lives_cat(const char *from, const char *to, boolean append)
Definition: utils.c:4019
int stored_layout_idx
Definition: main.h:690
void do_write_failed_error_s(const char *filename, const char *addinfo)
Definition: dialogs.c:3067
boolean is_realtime_aplayer(int ptype)
Definition: utils.c:1480
boolean save_frame_inner(int clip, int frame, const char *file_name, int width, int height, boolean from_osc)
Definition: saveplay.c:3656
uint32_t signed_endian
bitfield
Definition: main.h:530
LiVESWidget * menuentry
Definition: main.h:575
boolean check_file(const char *file_name, boolean check_exists)
check if file exists
Definition: utils.c:3844
boolean has_xwininfo
Definition: main.h:740
Definition: main.h:872
frames from video device
Definition: main.h:487
LiVESPixbuf * pull_lives_pixbuf(int clip, int frame, const char *image_ext, weed_timecode_t tc)
Definition: main.c:5300
boolean ask_permission_dialog(int what)
Definition: dialogs.c:3502
int nmonitors
Definition: main.h:778
lives_storage_status_t get_storage_status(const char *dir, uint64_t warn_level, uint64_t *dsval)
Definition: utils.c:840
int arate
audio playback rate
Definition: main.h:532
int lives_kill(lives_pid_t pid, int sig)
Definition: utils.c:1237
Definition: main.h:395
boolean no_proc_write_errors
skip write error dialogs in processing
Definition: main.h:701
int64_t aseek_pos
audio seek posn. (bytes) for when we switch clips
Definition: main.h:677
livespointer lives_memset(livespointer s, int c, size_t n)
Definition: effects-weed.c:134
void do_jack_noopen_warn3(void)
Definition: dialogs.c:2645
void lives_alarm_clear(int alarm_handle)
Definition: utils.c:1401
Definition: main.h:510
LiVESWidget * cancel_button
Definition: main.h:349
int lives_rmdir_with_parents(const char *dir)
Definition: utils.c:3917
void do_mt_set_mem_error(boolean has_mt, boolean trans)
Definition: dialogs.c:2693
const char * get_deinterlace_string(void)
Definition: saveplay.c:206
void set_redoable(const char *what, boolean sensitive)
Definition: utils.c:4487
boolean set_palette_colours(boolean force_reload)
Definition: main.c:1966
capability * get_capabilities(void)
Definition: main.c:2223
boolean can_read_from_config
Definition: main.h:719
Definition: main.h:511
uint16_t alpha
Definition: main.h:321
int insert_start
Definition: main.h:570
boolean keep_without_preview
allow keep, even when nopreview is set - TODO use only nopreview and nokeep
Definition: main.h:703
void switch_to_file(int old_file, int new_file)
Definition: main.c:7059
int undo_achans
Definition: main.h:653
ssize_t lives_write_le_buffered(int fd, livesconstpointer buf, size_t count, boolean allow_fail)
LiVESList * layout_map
Definition: main.h:626
void wait_for_stop(const char *stop_command)
Definition: saveplay.c:3623
boolean undo3_boolean
Definition: main.h:649
int lives_fputs(const char *s, FILE *stream)
Definition: utils.c:434
int lives_getuid(void)
Definition: utils.c:164
int undo_arps
audio sample rate
Definition: main.h:655
void do_encoder_img_ftm_error(render_details *rdet)
Definition: dialogs.c:3329
LiVESInterpType get_interp_value(short quality)
Definition: utils.c:5364
lives_clip_details_t
Definition: main.h:849
void do_bad_theme_error(const char *themefile)
Definition: dialogs.c:3424
const char * version(void)
int rowstride
Definition: main.h:552
int64_t afilesize
Definition: main.h:561
Definition: main.h:868
void desensitize(void)
Definition: main.c:3707
void add_to_recovery_file(const char *handle)
Definition: saveplay.c:5684
void do_set_locked_warning(const char *setname)
Definition: dialogs.c:3402
_palette * palette
Definition: main.c:89
frames from generator plugin
Definition: main.h:484
int save_event_frames(void)
Definition: saveplay.c:4550
int do_write_failed_error_s_with_retry(const char *fname, const char *errtext, LiVESWindow *transient) WARN_UNUSED
Definition: dialogs.c:3136
char * lives_strappend(char *string, int len, const char *newbit)
Definition: utils.c:1416
Definition: main.h:865
int lives_killpg(lives_pgid_t pgrp, int sig)
Definition: utils.c:1253
lives_interlace_t interlace
interlace type (if known - none, topfirst, bottomfirst or : see plugins.h)
Definition: main.h:545
void load_preview_image(boolean update_always)
Definition: main.c:4294
LiVESWidget * label3
Definition: main.h:345
void set_record(void)
int bpp
Definition: main.h:525
pid_t mainpid
Definition: main.h:784
void do_dir_perm_access_error(const char *dir_name)
Definition: dialogs.c:3316
uint64_t get_file_size(int fd)
Definition: utils.c:4210
double stored_layout_audio
Definition: main.h:691
uint32_t frames_done
Definition: main.h:351
void init_clipboard(void)
Definition: utils.c:1814
void show_manual_section(const char *lang, const char *section)
Definition: utils.c:4195
void switch_aud_to_sox(boolean set_pref)
Definition: utils.c:3390
void do_mt_backup_space_error(lives_mt *, int memreq_mb)
Definition: dialogs.c:2666
void do_no_decoder_error(const char *fname)
Definition: dialogs.c:2623
char * filename_from_fd(char *val, int fd)
Definition: utils.c:44
void switch_to_int_player(void)
Definition: main.h:390
uint32_t fastrand(void)
Definition: utils.c:5272
image could not be captured
Definition: main.h:444
void resize(double scale)
Definition: main.c:7630
void set_ce_frame_from_pixbuf(LiVESImage *image, LiVESPixbuf *pixbuf, lives_painter_t *)
Definition: main.c:3897
boolean do_abort_check(void)
Definition: dialogs.c:3323
boolean opening_only_audio
Definition: main.h:587
char * subst(const char *string, const char *from, const char *to)
Definition: utils.c:5131
yuv4mpeg stream
Definition: main.h:483
Definition: main.h:853
int lives_rmdir(const char *dir, boolean force)
Definition: utils.c:3891
render_details * rdet
Definition: events.h:208
void lives_list_free_strings(LiVESList *)
Definition: utils.c:4540
void switch_aud_to_mplayer2(boolean set_pref)
Definition: utils.c:3487
boolean check_for_disk_space(void)
Definition: saveplay.c:4878
mainwindow * mainw
Definition: main.c:91
record audio to selection
Definition: main.h:409
void load_frame_image(int frame)
Definition: main.c:5480
type for LiVES to LiVES streaming
Definition: main.h:486
int progress_end
Definition: main.h:573
ulong menuentry_func
Definition: main.h:576
boolean get_srt_text(lives_clip_t *sfile, double xtime)
Definition: pangotext.c:422
int * frame_index
Definition: main.h:665
void do_audrate_error_dialog(void)
Definition: dialogs.c:2754
char * rcfile
Definition: main.h:759
int do_abort_cancel_retry_dialog(const char *text, LiVESWindow *transient) WARN_UNUSED
Definition: dialogs.c:475
double stored_layout_fps
Definition: main.h:692
int64_t reltime
Definition: main.h:336
boolean save_sub_subtitles(lives_clip_t *sfile, double start_time, double end_time, double offset_time, const char *filename)
Definition: pangotext.c:847
void lives_list_free_all(LiVESList **)
Definition: utils.c:4562
LiVESPixbuf * mt_framedraw(lives_mt *, LiVESPixbuf *)
Definition: paramspecial.c:499
Definition: main.h:418
void subtitles_free(lives_clip_t *sfile)
Definition: pangotext.c:711
boolean add_lmap_error(lives_lmap_error_t lerror, const char *name, livespointer user_data, int clipno, int frameno, double atime, boolean affects_current)
Definition: utils.c:1910
void do_layout_ascrap_file_error(void)
Definition: dialogs.c:2248
boolean can_write_to_workdir
Definition: main.h:722
lives_lmap_error_t
Definition: multitrack.h:988
boolean has_smogrify
Definition: main.h:717
void do_dev_busy_error(const char *devstr)
Definition: dialogs.c:3344
LiVESWidget * processing
Definition: main.h:341
normal - kill background processes working on current clip
Definition: main.h:474
char * get_extension(const char *filename)
Definition: utils.c:2458
void set_menu_text(LiVESWidget *menu, const char *text, boolean use_mnemonic)
Definition: utils.c:3787
int lives_open3(const char *pathname, int flags, mode_t mode)
Definition: utils.c:147
int lives_creat_buffered(const char *pathname, int mode)
Definition: utils.c:587
boolean needs_update
loaded values were incorrect, update header
Definition: main.h:710
void set_preview_box_colours(void)
Definition: gui.c:3328
char * repl_workdir(const char *entry, boolean fwd)
Definition: utils.c:2557
void do_no_autolives_error(void)
Definition: dialogs.c:3463
boolean play_paused
Definition: main.h:582
void set_colours(LiVESWidgetColor *colf, LiVESWidgetColor *colb, LiVESWidgetColor *colf2, LiVESWidgetColor *colb2, LiVESWidgetColor *coli, LiVESWidgetColor *colt)
Definition: gui.c:192
boolean has_midistartstop
Definition: main.h:737
int fx_frame_pump
rfx frame pump for virtual clips (CLIP_TYPE_FILE)
Definition: main.h:669
double get_ratio_fps(const char *string)
Definition: utils.c:5052
Definition: main.h:871
Definition: main.h:861
void toggle_record(void)
Definition: gui.c:3591
void get_monitors(void)
Definition: main.c:236
boolean do_warning_dialog(const char *text)
Definition: dialogs.c:371
boolean after_foreign_play(void)
Definition: utils.c:3682
Definition: main.h:715
boolean startup_message_info(const char *msg)
Definition: main.c:3472
mainw->
Definition: mainwindow.h:393
uint16_t green
Definition: main.h:313
int frameno
Definition: main.h:610
double undo1_dbl
Definition: main.h:645
boolean do_yuv4m_open_warning(void)
Definition: dialogs.c:2463
void * ext_src
points to opaque source for non-disk types
Definition: main.h:659
boolean process_one(boolean visible)
Definition: dialogs.c:1082
uint16_t green
Definition: main.h:319
void do_jack_noopen_warn(void)
Definition: dialogs.c:2637
boolean prompt_remove_layout_files(void)
Definition: dialogs.c:2590
xprocess * proc_ptr
the processing window
Definition: main.h:555
void free_track_decoders(void)
Definition: main.c:5448
LiVESWidget * label2
Definition: main.h:344
boolean check_frame_count(int idx)
Definition: utils.c:2296
boolean undo2_boolean
Definition: main.h:648
boolean write_headers(lives_clip_t *file)
Definition: saveplay.c:3885
void do_rendered_fx_dialog(void)
Definition: dialogs.c:2552
void do_audio_import_error(void)
Definition: dialogs.c:2563
void do_cd_error_dialog(void)
Definition: dialogs.c:3480
user pressed &#39;Keep&#39;
Definition: main.h:456
double calc_time_from_frame(int clip, int frame)
Definition: utils.c:1448
ssize_t sizshrt
Definition: main.c:90
void get_menu_text_long(LiVESWidget *menuitem, char *text)
Definition: utils.c:3805
event_list completed
Definition: main.h:447
void do_jack_noopen_warn4(void)
Definition: dialogs.c:2649
uint64_t make_version_hash(const char *ver)
Definition: utils.c:2528
void get_dirname(char *filename)
Definition: utils.c:2411
Definition: main.h:389
void lives_close_all_file_buffers(void)
Definition: utils.c:473
int vsize
Definition: main.h:528
void splash_init(void)
Definition: gui.c:4265
char * get_new_install_msg(void)
Definition: dialogs.c:3455
void do_invalid_subs_error(void)
Definition: dialogs.c:3358
boolean has_composite
Definition: main.h:733
ssize_t lives_read(int fd, void *buf, size_t count, boolean allow_less)
Definition: utils.c:503
double freeze_fps
Definition: main.h:581
void do_need_mplayer_dialog(void)
Definition: dialogs.c:2210
boolean do_layout_alter_audio_warning(void)
Definition: dialogs.c:2609
livespointer lives_calloc(size_t n_blocks, size_t n_block_bytes)
Definition: effects-weed.c:139
char * get_dir(const char *filename)
Definition: utils.c:2429
int header_version
Definition: main.h:548
struct timeval tv
Definition: main.h:841
off_t lives_lseek_buffered_rdonly(int fd, off_t offset)
Definition: utils.c:655
int calc_frame_from_time3(int filenum, double time)
nearest frame mid
Definition: utils.c:1469
double raudio_time
Definition: main.h:602
resample/reorder/resize/apply effects
Definition: main.h:404
void close_ascrap_file(void)
Definition: saveplay.c:5093
void do_no_mplayer_sox_error(void)
Definition: dialogs.c:2204
void do_bad_layout_error(void)
Definition: dialogs.c:2731
Definition: main.h:867
LiVESWidget * create_question_dialog(const char *title, const char *text, LiVESWindow *parent)
Definition: dialogs.c:364
lives_interlace_t
Definition: main.h:508
weed_plant_t * event_list_back
Definition: main.h:623
void set_signal_handlers(SignalHandlerPointer sigfunc)
Definition: main.c:2986
Definition: main.h:385
char * insert_newlines(const char *text, int maxwidth)
Definition: utils.c:5149
void do_card_in_use_error(void)
Definition: dialogs.c:3339
boolean has_icedax
Definition: main.h:736
void splash_msg(const char *msg, double pct)
Definition: gui.c:4351
boolean do_erase_subs_warning(void)
Definition: dialogs.c:3383
void do_mt_undo_mem_error(void)
Definition: dialogs.c:2683
lives_undo_t
need this for event_list_t *
Definition: main.h:383
lives_painter_surface_t * laudio_drawable
Definition: main.h:705
corresponds to one clip in the GUI
Definition: main.h:523
weed_plant_t * event_list
Definition: main.h:622
boolean has_encoder_plugins
Definition: main.h:765
Definition: main.h:393
void do_lb_composite_error(void)
Definition: dialogs.c:2736
int calc_new_playback_position(int fileno, uint64_t otc, uint64_t *ntc)
Definition: utils.c:1551
int lives_cp_keep_perms(const char *from, const char *to)
Definition: utils.c:3967
boolean check_backend_return(lives_clip_t *sfile)
Definition: dialogs.c:759
int64_t lives_get_current_ticks(void)
Definition: utils.c:1303
#define GNU_CONST
Definition: main.h:300
char * clip_detail_to_string(lives_clip_details_t what, size_t *maxlenp)
Definition: utils.c:4625
int stored_layout_frame
layout map for the current layout
Definition: main.h:689
boolean check_dev_busy(char *devstr)
Definition: utils.c:4151
void open_set_file(const char *set_name, int clipnum)
Definition: saveplay.c:4329
int save_to_scrap_file(weed_plant_t *layer)
Definition: saveplay.c:4903
boolean startup_message_choice(const char *msg, int msgtype)
Definition: main.c:3458
boolean do_theme_exists_warn(const char *themename)
Definition: dialogs.c:3492
void lives_slist_free_all(LiVESSList **)
Definition: utils.c:4554
cancel but keep opening
Definition: main.h:432
char * ds_critical_msg(const char *dir, uint64_t dsval)
Definition: dialogs.c:643
LiVESPixbuf * lives_pixbuf_new_blank(int width, int height, int palette)
Definition: colourspace.c:10040
void add_to_recent(const char *filename, double start, int frames, const char *file_open_params)
Definition: utils.c:4323
ran out of preview frames
Definition: main.h:441
void lives_kill_subprocesses(const char *dirname, boolean kill_parent)
Definition: utils.c:4052
uint16_t blue
Definition: main.h:320
void unfade_background(void)
Definition: gui.c:3107
int do_blocking_info_dialog(const char *text)
Definition: dialogs.c:585
lives_cancel_t check_for_bad_ffmpeg(void)
Definition: utils.c:5445
boolean has_xdg_screensaver
Definition: main.h:743
boolean check_dir_access(const char *dir)
Definition: utils.c:4117
int do_info_dialog_with_transient(const char *text, boolean is_blocking, LiVESWindow *transient)
Definition: dialogs.c:622
void do_rmem_max_error(int size)
Definition: dialogs.c:2803
int old_frames
for deordering, etc.
Definition: main.h:562
#define ulong
Definition: main.h:150
Definition: main.h:419
boolean do_std_checks(const char *type_name, const char *type, size_t maxlen, const char *nreject)
Definition: utils.c:2177
Definition: main.h:866
ssize_t lives_readlink(const char *path, char *buf, size_t bufsiz)
Definition: utils.c:248
void disable_record(void)
Definition: gui.c:3596
Definition: main.h:851
cancelled because of error
Definition: main.h:462
double video_time
Definition: main.h:600
Definition: main.h:339
pid_t lives_getpid(void)
Definition: utils.c:116
int lives_chdir(const char *path, boolean allow_fail)
Definition: utils.c:854
void wait_for_bg_audio_sync(lives_clip_t *sfile)
Definition: utils.c:4235
boolean no_proc_read_errors
skip read error dialogs in processing
Definition: main.h:700
Definition: main.h:358
void get_menu_text(LiVESWidget *menu, char *text)
Definition: utils.c:3800
Definition: pangotext.h:39
void add_warn_check(LiVESBox *box, int warn_mask_number)
Definition: dialogs.c:117
int hsize
in pixels (NOT macropixels !)
Definition: main.h:527
Definition: main.h:411
boolean has_gdb
Definition: main.h:741
void get_location(const char *exe, char *val, int maxlen)
Definition: utils.c:2496
void switch_to_mplayer(void)
void get_frame_count(int idx)
Definition: utils.c:2339
effect processing finished during preview
Definition: main.h:435
void calc_maxspect(int rwidth, int rheight, int *cwidth, int *cheight)
Definition: utils.c:1772
lives_image_type_t img_type
Definition: main.h:686
lives_cancel_type_t
Definition: main.h:473
void make_custom_submenus(void)
Definition: gui.c:149
void do_need_mplayer_mpv_dialog(void)
Definition: dialogs.c:2216
boolean int_array_contains_value(int *array, int num_elems, int value)
Definition: utils.c:3811
boolean ensure_isdir(char *fname)
Definition: utils.c:2476
int do_header_read_error_with_retry(int clip) WARN_UNUSED
Definition: dialogs.c:3224
uint32_t get_signed_endian(boolean is_signed, boolean little_endian)
Definition: utils.c:5082
int myround(double n)
Definition: utils.c:1265
boolean lives_alarm_get(int alarm_handle)
Definition: utils.c:1361
boolean smog_version_correct
Definition: main.h:718
Definition: main.h:852
void resize_widgets_for_monitor(boolean get_play_times)
Definition: gui.c:3635
LiVESList * lives_list_delete_string(LiVESList *, char *string) WARN_UNUSED
Definition: utils.c:5379
boolean has_mplayer2
Definition: main.h:730
void do_pulse_lost_conn_error(void)
Definition: dialogs.c:3475
void switch_audio_clip(int new_file, boolean activate)
Definition: main.c:7290
capability * capable
some shared structures
Definition: main.c:88
LiVESWidget * progressbar
Definition: main.h:342
boolean cache_file_contents(const char *filename)
Definition: utils.c:4570
boolean read_file_details(const char *file_name, boolean only_check_for_audio)
Definition: saveplay.c:146
int end
Definition: main.h:569
int lives_getgid(void)
Definition: utils.c:237
uint64_t unique_id
this and the handle can be used to uniquely id a file
Definition: main.h:533
video playback completed
Definition: main.h:450
void do_upgrade_error_dialog(void)
Definition: dialogs.c:2542
boolean do_yesno_dialog(const char *text)
Definition: dialogs.c:452
void activate_url_inner(const char *link)
Definition: utils.c:4177
void d_print_done(void)
Definition: dialogs.c:3002
void load_start_image(int frame)
Definition: main.c:3943
void do_mt_no_jack_error(int warn_mask)
Definition: dialogs.c:2719
boolean pull_frame(weed_plant_t *layer, const char *image_ext, weed_timecode_t tc)
Definition: main.c:5165
void too_many_files(void)
Definition: dialogs.c:2185
boolean do_header_write_error(int clip)
Definition: dialogs.c:3239
void save_file(int clip, int start, int end, const char *filename)
Definition: saveplay.c:1184
void do_do_not_close_d(void)
Definition: dialogs.c:3418
void do_chdir_failed_error(const char *dir)
Definition: dialogs.c:3285
void do_layout_scrap_file_error(void)
Definition: dialogs.c:2243
void add_to_ascrap_mb(uint64_t bytes)
Definition: saveplay.c:4646
int lives_cp(const char *from, const char *to)
Definition: utils.c:3958
boolean do_set_rename_old_layouts_warning(const char *new_set)
Definition: dialogs.c:2675
lives_clip_type_t
Definition: main.h:481
void fade_background(void)
Definition: gui.c:2983
void play_file(void)
Definition: saveplay.c:2047
void do_after_crash_warning(void)
Definition: dialogs.c:2790
void show_lives(void)
Definition: gui.c:2802
int lives_rmglob(const char *files)
Definition: utils.c:3942
uint16_t red
Definition: main.h:312
boolean do_sub_type_warning(const char *ext, const char *type_ext)
Definition: dialogs.c:3388
void rewrite_recovery_file(void)
Definition: saveplay.c:5699
void do_encoder_acodec_error(void)
Definition: dialogs.c:2237
boolean is_writeable_dir(const char *dir)
Definition: utils.c:5284
void do_vpp_palette_error(void)
Definition: dialogs.c:2774
void backup_file(int clip, int start, int end, const char *filename)
Definition: saveplay.c:3743
boolean has_gconftool_2
Definition: main.h:742
boolean prepare_to_play_foreign(void)
Definition: utils.c:3540
char * get_menu_name(lives_clip_t *sfile)
Definition: gui.c:4160
boolean do_set_duplicate_warning(const char *new_set)
Definition: dialogs.c:2596
double vel
Definition: main.h:361
boolean is_loaded
should we continue loading if we come back to this clip
Definition: main.h:590
LiVESList * lives_list_append_unique(LiVESList *xlist, const char *add)
Definition: utils.c:1424
boolean save_clip_values(int which_file)
Definition: saveplay.c:37
int64_t f_size
Definition: main.h:560
int undo_asampsize
Definition: main.h:654
int lives_chmod(const char *target, const char *mode)
Definition: utils.c:4010
void break_me(void)
Definition: main.c:139
boolean lives_fsync(int fd)
Definition: utils.c:260
void do_quick_switch(int new_file)
Definition: main.c:7491
void get_frames_sizes(int fileno, int frame_to_test)
Definition: utils.c:2387
void do_set_noclips_error(const char *setname)
Definition: dialogs.c:3431
Definition: main.h:394
ulong deduce_file(const char *filename, double start_time, int end)
Definition: saveplay.c:212
Definition: main.h:311
int ncpus
Definition: main.h:780
void response_ok(LiVESButton *button, livespointer user_data)
Definition: dialogs.c:2987
uint64_t op_ds_warn_level
current disk space warning level for any output directory
Definition: main.h:697
void do_memory_error_dialog(void)
Definition: dialogs.c:687
special cancel for TV toy
Definition: main.h:468
void procw_desensitize(void)
Definition: main.c:3823
void do_system_failed_error(const char *com, int retval, const char *addinfo)
Definition: dialogs.c:3011
uint64_t lives_10pow(int pow) GNU_CONST
Definition: utils.c:1274
boolean startup_message_nonfatal_dismissable(const char *msg, int warning_mask)
Definition: main.c:3479
void remove_layout_files(LiVESList *lmap)
Definition: utils.c:2583
int lives_close_buffered(int fd)
Definition: utils.c:592
int lives_open2(const char *pathname, int flags)
Definition: utils.c:155
void set_interactive(boolean interactive)
Definition: gui.c:2862
Definition: main.h:397
boolean changed
Definition: main.h:574
uint16_t blue
Definition: main.h:314
int insert_end
Definition: main.h:571
boolean has_sox_sox
Definition: main.h:727
int lives_alarm_set(int64_t ticks)
Definition: utils.c:1322
int get_approx_ln(uint32_t val) GNU_CONST
Definition: utils.c:1289
boolean can_write_to_home
Definition: main.h:721
lives_cancel_t
cancel reason
Definition: main.h:424
boolean do_mt_rect_prompt(void)
Definition: dialogs.c:2725
boolean open_ascrap_file(void)
Definition: saveplay.c:4693
int achans
Definition: main.h:534
Definition: main.h:417
weed_plant_t * next_event
Definition: main.h:624
boolean is_ready
Definition: main.h:352
float LEFloat_to_BEFloat(float f) GNU_CONST
Definition: utils.c:1432
Definition: main.h:392
boolean check_for_ratio_fps(double fps)
Definition: utils.c:5034
void do_dvgrab_error(void)
Definition: dialogs.c:2763
boolean do_progress_dialog(boolean visible, boolean cancellable, const char *text)
Definition: dialogs.c:1519
void block_expose(void)
Definition: gui.c:3301
boolean get_new_handle(int index, const char *name)
Definition: saveplay.c:3350
LiVESWidget * preview_button
Definition: main.h:348
boolean has_sox_play
Definition: main.h:726
void get_filename(char *filename, boolean strip_dir)
Definition: utils.c:2447
Definition: main.h:856
Definition: main.h:398
LiVESWidget * pause_button
Definition: main.h:347
char * make_image_file_name(lives_clip_t *clip, int frame, const char *img_ext)
Definition: utils.c:2291
cancelled and paused
Definition: main.h:465
void do_jack_noopen_warn2(void)
Definition: dialogs.c:2661
boolean orig_file_name
Definition: main.h:577
boolean save_srt_subtitles(lives_clip_t *sfile, double start_time, double end_time, double offset_time, const char *filename)
Definition: pangotext.c:781
void calc_aframeno(int fileno)
Definition: utils.c:1529
lives_storage_status_t
disk/storage status values
Definition: mainwindow.h:215
void do_start_messages(void)
Definition: main.c:1863
boolean has_identify
Definition: main.h:734
Definition: main.h:493
void do_locked_in_vdevs_error(void)
Definition: dialogs.c:3414
Definition: main.h:494
void sensitize(void)
Definition: main.c:3522
LiVESWidget * label
Definition: main.h:343
boolean has_autolives
Definition: main.h:728
void catch_sigint(int signum)
Definition: main.c:189
Definition: main.h:396
Definition: main.h:869
lives_image_type_t lives_image_type_to_image_type(const char *lives_img_type)
Definition: utils.c:2284
void do_aud_during_play_error(void)
Definition: dialogs.c:682
boolean check_for_recovery_files(boolean auto_recover)
Definition: saveplay.c:5752
boolean get_clip_value(int which, lives_clip_details_t, void *retval, size_t maxlen)
Definition: utils.c:4721
int calc_frame_from_time(int filenum, double time)
nearest frame start
Definition: utils.c:1452
void do_no_in_vdevs_error(void)
Definition: dialogs.c:3410
char * get_upd_msg(int type)
Definition: dialogs.c:3439
int undo_end
Definition: main.h:633
void lives_srandom(unsigned int seed)
Definition: utils.c:97
void create_cfile(void)
Definition: saveplay.c:3256
int byte_order
Definition: main.h:782
void init_track_decoders(void)
Definition: main.c:5437
int undo4_int
Definition: main.h:643
double pointer_time
Definition: main.h:603
void do_mt_no_audchan_error(void)
Definition: dialogs.c:2715
const char * get_image_ext_for_type(lives_image_type_t imgtype)
Definition: utils.c:2267
double fps
Definition: main.h:526
char * lives_format_storage_space_string(uint64_t space)
Definition: utils.c:809
int cb_src
source clip for clipboard
Definition: main.h:708
void do_nojack_rec_error(void)
Definition: dialogs.c:2768
void get_total_time(lives_clip_t *file)
Definition: utils.c:3145
ulong open_file(const char *filename)
Definition: saveplay.c:235
void lives_suspend_resume_process(const char *dirname, boolean suspend)
Definition: utils.c:4083
char * myname_full
Definition: main.h:773
boolean ratio_fps
if the fps was set by a ratio
Definition: main.h:675
application quit
Definition: main.h:438
boolean has_convert
Definition: main.h:732
generator was stopped
Definition: main.h:453
double lives_fix(double val, int decimals) GNU_CONST
Definition: utils.c:1282
void create_LiVES(void)
Definition: gui.c:350
resample/resize and resample audio for encoding
Definition: main.h:401
int undo_start
Definition: main.h:632
int do_info_dialog(const char *text)
Definition: dialogs.c:539
boolean do_encoder_restrict_dialog(int width, int height, double fps, int fps_num, int fps_denom, int arate, int asigned, boolean swap_endian, boolean anr, boolean save_all)
Definition: dialogs.c:2349
Definition: main.h:406
boolean open_scrap_file(void)
Definition: saveplay.c:4651
Definition: main.h:858
boolean check_for_lock_file(const char *set_name, int type)
Definition: utils.c:2118
Definition: main.h:386
int undo3_int
Definition: main.h:642
boolean subtitles_init(lives_clip_t *sfile, char *fname, lives_subtitle_type_t)
Definition: pangotext.c:733
void switch_aud_to_mplayer(boolean set_pref)
Definition: utils.c:3434
short cpu_bits
Definition: main.h:770
uint64_t get_version_hash(const char *exe, const char *sep, int piece)
Definition: utils.c:2510
char * ds_warning_msg(const char *dir, uint64_t dsval, uint64_t cwarn, uint64_t nwarn)
Definition: dialogs.c:662
void do_decoder_palette_error(void)
Definition: dialogs.c:2779
void threaded_dialog_spin(double fraction)
Definition: dialogs.c:2895
int calc_frame_from_time2(int filenum, double time)
nearest frame end
Definition: utils.c:1460
livespointer _lives_realloc(livespointer ptr, size_t new_size)
Definition: effects-weed.c:94
boolean save_file_comments(int fileno)
Definition: saveplay.c:3583
double pb_fps
Definition: main.h:580
ssize_t lives_write(int fd, livesconstpointer buf, size_t count, boolean allow_fail)
#define WARN_UNUSED
Definition: main.h:298
Definition: main.h:857
boolean do_comments_dialog(int fileno, char *filename)
Definition: dialogs.c:2480
char * dummychar
Definition: main.h:1406
void fullscreen_internal(void)
Definition: gui.c:3240
char * myname
Definition: main.h:774
boolean has_python
Definition: main.h:767
Definition: main.h:850
Definition: main.h:870
lives_subtitle_type_t
Definition: pangotext.h:13
LiVESList * lives_list_copy_strings(LiVESList *list)
Definition: utils.c:5395
#define FALSE
Definition: videoplugin.h:56
boolean do_warning_dialog_with_check(const char *text, int warn_mask_number)
Definition: dialogs.c:376
void load_end_image(int frame)
Definition: main.c:4118
Definition: main.h:387
void lives_sync(void)
Definition: utils.c:270
ssize_t lives_read_le_buffered(int fd, void *buf, size_t count, boolean allow_less)
Definition: utils.c:733
boolean do_original_lost_warning(const char *fname)
Definition: dialogs.c:2613
int do_blocking_error_dialog(const char *text)
Definition: dialogs.c:571
int lives_list_strcmp_index(LiVESList *list, livesconstpointer data)
Definition: utils.c:4306
boolean has_jackd
Definition: main.h:738
boolean add_file_info(const char *check_handle, boolean aud_only)
Definition: saveplay.c:3382
double laudio_time
Definition: main.h:601
boolean string_lists_differ(LiVESList *, LiVESList *)
Definition: utils.c:5411
boolean undoable
Definition: main.h:636
Definition: main.h:509
void do_lb_convert_error(void)
Definition: dialogs.c:2742
double old_laudio_time
Definition: main.h:606
Definition: main.h:855
int do_error_dialog_with_check(const char *text, int warn_mask_number)
Definition: dialogs.c:557
void d_print_cancelled(void)
Definition: dialogs.c:2992
void zero_spinbuttons(void)
Definition: utils.c:3261
user pressed stop
Definition: main.h:429
int arps
audio sample rate
Definition: main.h:529
boolean opening_loc
Definition: main.h:588
boolean switch_aud_to_jack(void)
Definition: utils.c:3275