summaryrefslogtreecommitdiff
path: root/kicad
diff options
context:
space:
mode:
authorWerner Almesberger <werner@almesberger.net>2016-08-20 23:17:29 -0300
committerWerner Almesberger <werner@almesberger.net>2016-08-20 23:17:29 -0300
commit5654a1370928bc8c1f257fd21e4f669d50d5ded7 (patch)
tree5ff599d401bd49b9822f60997fe8e0d5c6e18b72 /kicad
parent65163e5c9b853d4fb3d98000c4abfbd65bb782f2 (diff)
downloadeeshow-5654a1370928bc8c1f257fd21e4f669d50d5ded7.tar.gz
eeshow-5654a1370928bc8c1f257fd21e4f669d50d5ded7.tar.bz2
eeshow-5654a1370928bc8c1f257fd21e4f669d50d5ded7.zip
eeshow/kicad/delta.c: improve sectioning
Diffstat (limited to 'kicad')
-rw-r--r--kicad/delta.c34
1 files changed, 20 insertions, 14 deletions
diff --git a/kicad/delta.c b/kicad/delta.c
index 99f4a89..a257784 100644
--- a/kicad/delta.c
+++ b/kicad/delta.c
@@ -352,20 +352,7 @@ bool sheet_eq(const struct sheet *a, const struct sheet *b)
}
-static void free_obj(struct sch_obj *obj)
-{
- /* there may be more to free once we get into cloning components */
- free(obj);
-}
-
-
-static void init_res(struct sheet *res)
-{
- res->title = NULL;
- res->objs = NULL;
- res->next_obj = &res->objs;
- res->next = NULL;
-}
+/* ----- Merge wires ------------------------------------------------------- */
static int min(int a, int b)
@@ -436,6 +423,25 @@ static void merge_wires(struct sch_obj *a)
}
+/* ----- Split objects from A and B into only-A, only-B, and A-and-B ------- */
+
+
+static void free_obj(struct sch_obj *obj)
+{
+ /* there may be more to free once we get into cloning components */
+ free(obj);
+}
+
+
+static void init_res(struct sheet *res)
+{
+ res->title = NULL;
+ res->objs = NULL;
+ res->next_obj = &res->objs;
+ res->next = NULL;
+}
+
+
void delta(const struct sheet *a, const struct sheet *b,
struct sheet *res_a, struct sheet *res_b, struct sheet *res_ab)
{