HDR: Add colorinfo to exception logs.

Format.toString unfortunately doesn't log colorInfo, and as Format holds a very
large set of values, it's unclear that it should. ColorInfo is useful for codec
exceptions though, so log this in ExportException.createForCodec.

PiperOrigin-RevId: 510475520
This commit is contained in:
huangdarwin 2023-02-17 19:08:04 +00:00 committed by Andrew Lewis
parent 5e93616ad2
commit 84fe683ca3

View File

@ -229,6 +229,9 @@ public final class ExportException extends Exception {
boolean isDecoder,
Format format) {
String details = "format=" + format;
if (isVideo) {
details += ", colorInfo=" + format.colorInfo;
}
return createForCodec(cause, errorCode, isVideo, isDecoder, details);
}