Index: trunk/src/buffer.c =================================================================== --- trunk/src/buffer.c (revision 9771) +++ trunk/src/buffer.c (revision 9772) @@ -418,7 +418,6 @@ } } - void pcb_buffer_mirror(pcb_board_t *pcb, pcb_buffer_t *Buffer) { int i, num_layers; @@ -442,26 +441,7 @@ /* set buffer offset to 'mark' position */ Buffer->X = PCB_SWAP_X(Buffer->X); Buffer->Y = PCB_SWAP_Y(Buffer->Y); - PCB_VIA_LOOP(Buffer->Data); - { - pcb_via_mirror(Buffer->Data, via); - } - PCB_END_LOOP; - PCB_LINE_ALL_LOOP(Buffer->Data); - { - pcb_line_mirror(layer, line); - } - PCB_ENDALL_LOOP; - PCB_ARC_ALL_LOOP(Buffer->Data); - { - pcb_arc_mirror(layer, arc); - } - PCB_ENDALL_LOOP; - PCB_POLY_ALL_LOOP(Buffer->Data); - { - pcb_poly_mirror(layer, polygon); - } - PCB_ENDALL_LOOP; + pcb_data_mirror(Buffer->Data); pcb_set_buffer_bbox(Buffer); } Index: trunk/src/data.c =================================================================== --- trunk/src/data.c (revision 9771) +++ trunk/src/data.c (revision 9772) @@ -403,3 +403,27 @@ return NULL; } + +void pcb_data_mirror(pcb_data_t *data) +{ + PCB_VIA_LOOP(data); + { + pcb_via_mirror(data, via); + } + PCB_END_LOOP; + PCB_LINE_ALL_LOOP(data); + { + pcb_line_mirror(layer, line); + } + PCB_ENDALL_LOOP; + PCB_ARC_ALL_LOOP(data); + { + pcb_arc_mirror(layer, arc); + } + PCB_ENDALL_LOOP; + PCB_POLY_ALL_LOOP(data); + { + pcb_poly_mirror(layer, polygon); + } + PCB_ENDALL_LOOP; +} Index: trunk/src/data.h =================================================================== --- trunk/src/data.h (revision 9771) +++ trunk/src/data.h (revision 9772) @@ -136,4 +136,7 @@ pcb_board_t *pcb_data_get_top(pcb_data_t *data); +void pcb_data_mirror(pcb_data_t *data); + + #endif