• Home
  • Raw
  • Download

Lines Matching refs:stream

28 static void print_table_header(SkFILEWStream* stream,  in print_table_header()  argument
35 stream->writeText("<table>\n"); in print_table_header()
36 stream->writeText("<tr><th>"); in print_table_header()
37 stream->writeText("select image</th>\n<th>"); in print_table_header()
41 stream->writeText("SkDiff run at "); in print_table_header()
42 stream->writeDecAsText(dt.fHour); in print_table_header()
43 stream->writeText(":"); in print_table_header()
45 stream->writeText("0"); in print_table_header()
47 stream->writeDecAsText(dt.fMinute); in print_table_header()
48 stream->writeText(":"); in print_table_header()
50 stream->writeText("0"); in print_table_header()
52 stream->writeDecAsText(dt.fSecond); in print_table_header()
53 stream->writeText("<br>"); in print_table_header()
55 stream->writeDecAsText(matchCount); in print_table_header()
56 stream->writeText(" of "); in print_table_header()
57 stream->writeDecAsText(differences.count()); in print_table_header()
58 stream->writeText(" diffs matched "); in print_table_header()
60 stream->writeText("exactly"); in print_table_header()
62 stream->writeText("within "); in print_table_header()
63 stream->writeDecAsText(colorThreshold); in print_table_header()
64 stream->writeText(" color units per component"); in print_table_header()
66 stream->writeText(".<br>"); in print_table_header()
67 stream->writeText("</th>\n<th>"); in print_table_header()
68 stream->writeText("every different pixel shown in white"); in print_table_header()
69 stream->writeText("</th>\n<th>"); in print_table_header()
70 stream->writeText("color difference at each pixel"); in print_table_header()
71 stream->writeText("</th>\n<th>baseDir: "); in print_table_header()
72 stream->writeText(baseDir.c_str()); in print_table_header()
73 stream->writeText("</th>\n<th>comparisonDir: "); in print_table_header()
74 stream->writeText(comparisonDir.c_str()); in print_table_header()
75 stream->writeText("</th>\n"); in print_table_header()
76 stream->writeText("</tr>\n"); in print_table_header()
79 static void print_pixel_count(SkFILEWStream* stream, const DiffRecord& diff) { in print_pixel_count() argument
80 stream->writeText("<br>("); in print_pixel_count()
81 stream->writeDecAsText(static_cast<int>(diff.fFractionDifference * in print_pixel_count()
84 stream->writeText(" pixels)"); in print_pixel_count()
93 static void print_checkbox_cell(SkFILEWStream* stream, const DiffRecord& diff) { in print_checkbox_cell() argument
94 stream->writeText("<td><input type=\"checkbox\" name=\""); in print_checkbox_cell()
95 stream->writeText(diff.fBase.fFilename.c_str()); in print_checkbox_cell()
96 stream->writeText("\" checked=\"yes\"></td>"); in print_checkbox_cell()
99 static void print_label_cell(SkFILEWStream* stream, const DiffRecord& diff) { in print_label_cell() argument
102 stream->writeText("<td><b>"); in print_label_cell()
103 stream->writeText(diff.fBase.fFilename.c_str()); in print_label_cell()
104 stream->writeText("</b><br>"); in print_label_cell()
113 stream->writeText("Image sizes differ</td>"); in print_label_cell()
117 stream->writeText(metricBuf); in print_label_cell()
118 stream->writeText(" of pixels differ"); in print_label_cell()
119 stream->writeText("\n ("); in print_label_cell()
121 stream->writeText(metricBuf); in print_label_cell()
122 stream->writeText(" weighted)"); in print_label_cell()
125 print_pixel_count(stream, diff); in print_label_cell()
127 stream->writeText("<br>"); in print_label_cell()
129 stream->writeText("<br>Average alpha channel mismatch "); in print_label_cell()
130 stream->writeDecAsText(SkScalarRoundToInt(diff.fAverageMismatchA)); in print_label_cell()
133 stream->writeText("<br>Max alpha channel mismatch "); in print_label_cell()
134 stream->writeDecAsText(SkScalarRoundToInt(diff.fMaxMismatchA)); in print_label_cell()
136 stream->writeText("<br>Total alpha channel mismatch "); in print_label_cell()
137 stream->writeDecAsText(static_cast<int>(diff.fTotalMismatchA)); in print_label_cell()
139 stream->writeText("<br>"); in print_label_cell()
140 stream->writeText("<br>Average color mismatch "); in print_label_cell()
141 stream->writeDecAsText(SkScalarRoundToInt(MAX3(diff.fAverageMismatchR, in print_label_cell()
144 stream->writeText("<br>Max color mismatch "); in print_label_cell()
145 stream->writeDecAsText(MAX3(diff.fMaxMismatchR, in print_label_cell()
148 stream->writeText("</td>"); in print_label_cell()
151 stream->writeText("Could not compare.<br>base: "); in print_label_cell()
152 stream->writeText(DiffResource::getStatusDescription(diff.fBase.fStatus)); in print_label_cell()
153 stream->writeText("<br>comparison: "); in print_label_cell()
154 stream->writeText(DiffResource::getStatusDescription(diff.fComparison.fStatus)); in print_label_cell()
155 stream->writeText("</td>"); in print_label_cell()
163 static void print_image_cell(SkFILEWStream* stream, const SkString& path, int height) { in print_image_cell() argument
164 stream->writeText("<td><a href=\""); in print_image_cell()
165 stream->writeText(path.c_str()); in print_image_cell()
166 stream->writeText("\"><img src=\""); in print_image_cell()
167 stream->writeText(path.c_str()); in print_image_cell()
168 stream->writeText("\" height=\""); in print_image_cell()
169 stream->writeDecAsText(height); in print_image_cell()
170 stream->writeText("px\"></a></td>"); in print_image_cell()
173 static void print_link_cell(SkFILEWStream* stream, const SkString& path, const char* text) { in print_link_cell() argument
174 stream->writeText("<td><a href=\""); in print_link_cell()
175 stream->writeText(path.c_str()); in print_link_cell()
176 stream->writeText("\">"); in print_link_cell()
177 stream->writeText(text); in print_link_cell()
178 stream->writeText("</a></td>"); in print_link_cell()
181 static void print_diff_resource_cell(SkFILEWStream* stream, DiffResource& resource, in print_diff_resource_cell() argument
186 print_link_cell(stream, resource.fFilename, "N/A"); in print_diff_resource_cell()
193 print_link_cell(stream, resource.fFullPath, "N/A"); in print_diff_resource_cell()
197 stream->writeText("<td>N/A</td>"); in print_diff_resource_cell()
203 print_image_cell(stream, resource.fFilename, height); in print_diff_resource_cell()
209 print_image_cell(stream, resource.fFullPath, height); in print_diff_resource_cell()
212 static void print_diff_row(SkFILEWStream* stream, DiffRecord& diff, const SkString& relativePath) { in print_diff_row() argument
213 stream->writeText("<tr>\n"); in print_diff_row()
214 print_checkbox_cell(stream, diff); in print_diff_row()
215 print_label_cell(stream, diff); in print_diff_row()
216 print_diff_resource_cell(stream, diff.fWhite, relativePath, true); in print_diff_row()
217 print_diff_resource_cell(stream, diff.fDifference, relativePath, true); in print_diff_row()
218 print_diff_resource_cell(stream, diff.fBase, relativePath, false); in print_diff_row()
219 print_diff_resource_cell(stream, diff.fComparison, relativePath, false); in print_diff_row()
220 stream->writeText("</tr>\n"); in print_diff_row()
221 stream->flush(); in print_diff_row()