From: Ian Jackson Date: Sun, 16 Aug 2009 20:41:27 +0000 (+0100) Subject: Cope with display which doesn't have a commod pixel-exactly at the top X-Git-Tag: 3.2~5 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~yarrgweb/git?p=ypp-sc-tools.main.git;a=commitdiff_plain;h=8d1d320d691c11fc37ef259c4e6b93857ed13eb6 Cope with display which doesn't have a commod pixel-exactly at the top --- diff --git a/yarrg/structure.c b/yarrg/structure.c index f10addc..99042d0 100644 --- a/yarrg/structure.c +++ b/yarrg/structure.c @@ -313,12 +313,16 @@ void find_structure(const CanonImage *im, #define CHECK_STRIP_BORDER(tlbr,xy,increm) \ do { \ - Point csb_p; \ + Point csb_p, csb_p2; \ Rect csb_r; \ csb_p= s.mr.tl; \ csb_p.x++; csb_p.y++; \ + csb_p2= csb_p; \ + csb_p2.x++; csb_p2.y++; \ csb_p.xy= s.mr.tlbr.xy; \ - if (get_p(csb_p)=='+') { \ + csb_p2.xy= s.mr.tlbr.xy; \ + if (get_p(csb_p)=='+' && \ + get_p(csb_p2)=='+') { \ csb_r= s.mr; \ csb_r.tl.xy= csb_p.xy; \ csb_r.br.xy= csb_p.xy; \