1
0
mirror of git://projects.qi-hardware.com/fped.git synced 2024-11-18 10:41:31 +02:00
fped/overlap.h
werner e6b2658a65 Added relaxation of pad overlap checking. Not GUI-settable yet.
- README, fpd.l, fpd.y: added directives "allow touch" and "allow overlap" to
  make overlap checking more permissive
- dump.c (dump_allow, dump): generate "allow" directive
- obj.h, obj.c (allow_overlap): added global variable for strictness of overlap
  checking
- overlap.h, overlap.c (overlap, ...), layer.h, layer.c (refine_layers):
  strictness of overlap checking is passed as an argument
- hole.c (check_through_hole), layer.h, layer.c (refine_copper), obj.c
  (instantiate): updated callers of "overlap" to provide "allow" argument



git-svn-id: http://svn.openmoko.org/trunk/eda/fped@5974 99fdad57-331a-0410-800a-d7fa5415bdb3
2010-08-09 04:16:37 +00:00

46 lines
939 B
C

/*
* overlap.h - Test for overlaps
*
* Written 2009, 2010 by Werner Almesberger
* Copyright 2009, 2010 by Werner Almesberger
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*/
#ifndef OVERLAP_H
#define OVERLAP_H
enum allow_overlap {
ao_none,
ao_touch,
ao_any,
};
/*
* Avoid inst.h -> layer.h -> overlay.h -> inst.h loop
*/
struct inst;
/*
* "inside" returns 1 if "a" is completely enclosed by "b". If "a" == "b",
* that also counts as "a" being inside "b".
*/
int inside(const struct inst *a, const struct inst *b);
/*
* "overlap" returns 1 if "a" and "b" have at least one point in common.
*/
int overlap(const struct inst *a, const struct inst *b,
enum allow_overlap allow);
#endif /* !OVERLAP_H */