c2a3e34e0d246747a3449b8902469a913c88f3a2 braney Tue Mar 11 13:43:50 2014 -0700 fix an issue with a function definition change that was breaking BioPerl diff --git src/lib/bwgCreate.c src/lib/bwgCreate.c index 7cf8e3f..ff7aff7 100644 --- src/lib/bwgCreate.c +++ src/lib/bwgCreate.c @@ -1178,43 +1178,58 @@ { if (sameString(section->chrom, nextSection->chrom)) { if (section->end > nextSection->start) { errAbort("There's more than one value for %s base %d (in coordinates that start with 1).\n", section->chrom, nextSection->start+1); } } } } return sectionList; } -void bigWigFileCreate( +void bigWigFileCreateEx( char *inName, /* Input file in ascii wiggle format. */ char *chromSizes, /* Two column tab-separated file: <chromosome> <size>. */ int blockSize, /* Number of items to bundle in r-tree. 1024 is good. */ int itemsPerSlot, /* Number of items in lowest level of tree. 512 is good. */ boolean clipDontDie, /* If TRUE then clip items off end of chrom rather than dying. */ boolean compress, /* If TRUE then compress data. */ boolean keepAllChromosomes, /* If TRUE then store all chromosomes in chromosomal b-tree. */ boolean fixedSummaries, /* If TRUE then impose fixed summary levels. */ char *outName) /* Convert ascii format wig file (in fixedStep, variableStep or bedGraph format) * to binary big wig format. */ { /* This code needs to agree with code in two other places currently - bigBedFileCreate, * and bbiFileOpen. I'm thinking of refactoring to share at least between * bigBedFileCreate and bigWigFileCreate. It'd be great so it could be structured * so that it could send the input in one chromosome at a time, and send in the zoom * stuff only after all the chromosomes are done. This'd potentially reduce the memory * footprint by a factor of 2 or 4. Still, for now it works. -JK */ struct hash *chromSizeHash = bbiChromSizesFromFile(chromSizes); struct lm *lm = lmInit(0); struct bwgSection *sectionList = bwgParseWig(inName, clipDontDie, chromSizeHash, itemsPerSlot, lm); if (sectionList == NULL) errAbort("%s is empty of data", inName); bwgCreate(sectionList, chromSizeHash, blockSize, itemsPerSlot, compress, keepAllChromosomes, fixedSummaries, outName); lmCleanup(&lm); } +void bigWigFileCreate( + char *inName, /* Input file in ascii wiggle format. */ + char *chromSizes, /* Two column tab-separated file: <chromosome> <size>. */ + int blockSize, /* Number of items to bundle in r-tree. 1024 is good. */ + int itemsPerSlot, /* Number of items in lowest level of tree. 512 is good. */ + boolean clipDontDie, /* If TRUE then clip items off end of chrom rather than dying. */ + boolean compress, /* If TRUE then compress data. */ + char *outName) +/* Convert ascii format wig file (in fixedStep, variableStep or bedGraph format) + * to binary big wig format. */ +{ +bigWigFileCreateEx( inName, chromSizes, blockSize, itemsPerSlot, clipDontDie, + compress, FALSE, FALSE, outName); +} +