← Back to team overview

kicad-developers team mailing list archive

Re: Polygon work

 

--=-nzMAzOdAK3BiIJEfEiyu Content-Type: text/plain
Content-Transfer-Encoding: 7bit

ke, 2009-01-21 kello 18:05 +0100, jean-pierre charras - INPG kirjoitti:

> Is really a bug ? just needs refinements.
> The main goal of this miter is to avoid (or reduce) problems with
> kbool.

That depends on the interpretation :) Yes, the bug doesn't matter too
much in oval thermals, but please take a look at the attached examples.
They should show five mil (fourth of a thermal gap) miters. I'm unsure
if this only affects tracing on common nets or not. If it is a global
problem that could lead to drc errors.

> A full optimization could be:
> a -calculate filled areas including pads (as now)
> b- test for unused stub (currently done after creating thermal
> shapes) 
> ising the current code.
> c - creating thermal shapes using a more refined shape calculations 
> taking in account the fact some stubs must be created, and others not.

That seems good. I think it would also make sense to work out some
primitive way of caching thermals and cutouts. Like per module basis.

> I believe you are volunteer to refine thermal shape calculation. Am i 
> wrong ?

No, you are very right. I'm willing to do that, but I'll probably need
some help from you and/or Rok for full optimization.

-Vesa
 --=-nzMAzOdAK3BiIJEfEiyu Content-Disposition: attachment; filename="kicad_miter_1mil.png"
Content-Type: image/png; name="kicad_miter_1mil.png"
Content-Transfer-Encoding: base64

[Attachment content not displayed.] --=-nzMAzOdAK3BiIJEfEiyu Content-Disposition: attachment; filename="kicad_miter_10mil.png"
Content-Type: image/png; name="kicad_miter_10mil.png"
Content-Transfer-Encoding: base64

[Attachment content not displayed.] --=-nzMAzOdAK3BiIJEfEiyu Content-Disposition: attachment; filename="miter.patch"
Content-Type: text/x-patch; name="miter.patch"; charset="UTF-8"
Content-Transfer-Encoding: 7bit

Index: ../pcbnew/zones_convert_brd_items_to_polygons.cpp
===================================================================
--- ../pcbnew/zones_convert_brd_items_to_polygons.cpp	(revision 1534)
+++ ../pcbnew/zones_convert_brd_items_to_polygons.cpp	(working copy)
@@ -936,10 +945,13 @@

// The first point of polygon buffer is left lower corner, second the crosspoint of thermal spoke sides,
// the third is upper right corner and the rest are rounding vertices going anticlockwise. Note the inveted Y-axis in CG.
- corners_buffer.push_back( wxPoint( -dx, -copper_thickness.y / 2 ) );
+ 
+ corners_buffer.push_back( wxPoint( -dx , -(aThermalGap / 4 + copper_thickness.y / 2) ) );	// Adds small miters to zone
+ corners_buffer.push_back( wxPoint( -(dx - aThermalGap / 4) , -copper_thickness.y / 2 ) );	// fill and spoke corner
corners_buffer.push_back( wxPoint( -copper_thickness.x / 2, -copper_thickness.y / 2 ) );
- corners_buffer.push_back( wxPoint( -copper_thickness.x / 2, -dy ) );
-
+ corners_buffer.push_back( wxPoint( -copper_thickness.x / 2, -(dy - aThermalGap / 4) ) );
+	corners_buffer.push_back( wxPoint( -(aThermalGap / 4 + copper_thickness.x / 2), -dy ) );
+	
angle = aPad.m_Orient;
int rounding_radius = (int) ( aThermalGap * s_Correction ); // Corner rounding radius
int angle_pg; // Polygon increment angle
 --=-nzMAzOdAK3BiIJEfEiyu-- 




Follow ups

References