diff --git a/libisoburn/trunk/src/isoburn.c b/libisoburn/trunk/src/isoburn.c index 012694ea..c58ea2ab 100644 --- a/libisoburn/trunk/src/isoburn.c +++ b/libisoburn/trunk/src/isoburn.c @@ -238,7 +238,7 @@ int isoburn_prepare_disc_aux(struct burn_drive *d, struct burn_disc **disc, struct isoburn *o; struct ecma119_source_opts wopts; enum burn_disc_status state; - int ret; + int ret, chunks; ret= isoburn_find_emulator(&o, d, 0); if(ret<0 || o==NULL) @@ -295,7 +295,13 @@ int isoburn_prepare_disc_aux(struct burn_drive *d, struct burn_disc **disc, /* TODO check return values for failure. propertly clean-up on error */ - o->fifo = burn_fifo_source_new(wsrc, 2048, 2000, 0); + chunks= 32; + if(opts->fifo_size >= 64*1024 && opts->fifo_size <= 1024.0 * 1024.0 * 1024.0){ + chunks= opts->fifo_size/2048; + if(chunks*2048 < opts->fifo_size) + chunks++; + } + o->fifo = burn_fifo_source_new(wsrc, 2048, chunks, 0); burn_source_free(wsrc); if (o->fifo == NULL) { fprintf(stderr, "Cannot attach fifo\n"); diff --git a/libisoburn/trunk/src/libisoburn.h b/libisoburn/trunk/src/libisoburn.h index 02870d99..429da1cf 100644 --- a/libisoburn/trunk/src/libisoburn.h +++ b/libisoburn/trunk/src/libisoburn.h @@ -107,9 +107,12 @@ struct isoburn_read_opts { }; /** - * Options for image generation. + * Options for image generation by libisofs and image transport to libburn. */ struct isoburn_source_opts { + + /* Options for image generation */ + int level; /**< ISO level to write at. */ int flags; /**< Which extensions to support. */ int relaxed_constraints; /**< see ecma119_relaxed_constraints_flag */ @@ -168,6 +171,19 @@ struct isoburn_source_opts { uid_t uid; /**< uid to use when replace_uid is set. */ char *input_charset; /**< NULL to use default charset */ char *ouput_charset; /**< NULL to use default charset */ + + + /* Options for image transport */ + + /** The number of bytes to be used for the fifo which decouples libisofs + and libburn for better throughput and for reducing the risk of + interrupting signals hitting the libburn thread which operates the + MMC drive. + The size will be rounded up to the next full 2048. + Minimum is 64kiB, maximum is 1 GiB (but that is too much anyway). + */ + int fifo_size; + }; /** Load the ISO filesystem directory tree from the media in the given drive. diff --git a/libisoburn/trunk/test/xorriso_timestamp.h b/libisoburn/trunk/test/xorriso_timestamp.h index 4a72f98f..0f686e30 100644 --- a/libisoburn/trunk/test/xorriso_timestamp.h +++ b/libisoburn/trunk/test/xorriso_timestamp.h @@ -1 +1 @@ -#define Xorriso_timestamP "2007.10.22.211928" +#define Xorriso_timestamP "2007.10.23.122349"