b2acdf83569bcb30013ed09d885d3f48b19c1d4e jcasper Wed Sep 11 16:03:26 2019 -0700 Better support for hic composite tracks, and hic trackUi pages now include metadata from the file, refs #22316 diff --git src/hg/inc/hicUi.h src/hg/inc/hicUi.h index 974a979..379a281 100644 --- src/hg/inc/hicUi.h +++ src/hg/inc/hicUi.h @@ -25,53 +25,57 @@ #define HIC_RESOLUTION "resolution" #define HIC_DRAW_AUTOSCALE "autoscale" #define HIC_DRAW_MAX_VALUE "max" #define HIC_DRAW_MAX_VALUE_DEFAULT 100 #define HIC_DRAW_COLOR "color" #define HIC_DRAW_BG_COLOR "bgColor" /* Default to drawing red on a white background */ #define HIC_DRAW_COLOR_DEFAULT "#ff0000" #define HIC_DRAW_BG_COLOR_DEFAULT "#ffffff" void hicCfgUi(char *database, struct cart *cart, struct trackDb *tdb, char *track, char *title, boolean boxed); /* Draw the list of track configuration options for Hi-C tracks */ -char *hicUiFetchResolution(struct cart *cart, char *track, struct hicMeta *meta); +void hicCfgUiComposite(struct cart *cart, struct trackDb *tdb, char *track, + char *title, boolean boxed); +/* Draw the (empty) list of track configuration options for a composite of Hi-C tracks */ + +char *hicUiFetchResolution(struct cart *cart, struct trackDb *tdb, struct hicMeta *meta); /* Return the current resolution selection, or the default if none * has been selected. */ -int hicUiFetchResolutionAsInt(struct cart *cart, char *track, struct hicMeta *meta, int windowSize); +int hicUiFetchResolutionAsInt(struct cart *cart, struct trackDb *tdb, struct hicMeta *meta, int windowSize); /* Return the current resolution selection as an integer. If there is no selection, or if "Auto" * has been selected, return the largest available value that still partitions the window into at * least 5000 bins. */ -char *hicUiFetchNormalization(struct cart *cart, char *track, struct hicMeta *meta); +char *hicUiFetchNormalization(struct cart *cart, struct trackDb *tdb, struct hicMeta *meta); /* Return the current normalization selection, or the default if none * has been selected. Right now this is a hard-coded set specifically for * .hic files, but in the future this list might be dynamically determined by * the contents and format of the Hi-C file. */ -char *hicUiFetchDrawMode(struct cart *cart, char *track); +char *hicUiFetchDrawMode(struct cart *cart, struct trackDb *tdb); /* Return the current draw mode selection, or the default if none * has been selected. */ -char *hicUiFetchDrawColor(struct cart *cart, char *track); +char *hicUiFetchDrawColor(struct cart *cart, struct trackDb *tdb); /* Retrieve the HTML hex code for the color to draw the * track values in (e.g., #00ffa1) */ -char *hicUiFetchBgColor(struct cart *cart, char *track); +char *hicUiFetchBgColor(struct cart *cart, struct trackDb *tdb); /* Retrieve the HTML hex code of the background color for the * track. This is the color associated with scores at or close to 0. */ -boolean hicUiFetchAutoScale(struct cart *cart, char *track); +boolean hicUiFetchAutoScale(struct cart *cart, struct trackDb *tdb); /* Returns whether the track is configured to automatically scale its color range * depending on the scores present in the window (true), or if it should stick to a * gradient based on the user's selected maximum value (false). */ -double hicUiFetchMaxValue(struct cart *cart, char *track); +double hicUiFetchMaxValue(struct cart *cart, struct trackDb *tdb); /* Retrieve the score value at which the draw color reaches its * its maximum intensity. Any scores above this value will * share that same draw color. */ #endif