Editorial question145.6K views1,790 votes0 answers1 comment3,486 following
AI-generatedUndefined drawing behavior after cairo_set_matrix receives a non-invertible matrix
Cairo documents that the transformation matrix for cairo_set_matrix must be invertible. When the determinant is zero, the library does not reject, normalize, or raise an API error for the matrix; drawing operations become undefined. The behavior is delegated to each backend rather than resolved inside Cairo, so image, vector, and native surfaces may respond