fix minor compil warnings
This commit is contained in:
parent
000f810161
commit
cdad02336d
|
@ -1946,7 +1946,7 @@ void SHAPE_POLY_SET::triangulateSingle( const POLYGON& aPoly,
|
|||
|
||||
std::unique_ptr<p2t::CDT> cdt( new p2t::CDT( outline ) );
|
||||
|
||||
for( int i = 1; i < aPoly.size(); i++ )
|
||||
for( unsigned i = 1; i < aPoly.size(); i++ )
|
||||
{
|
||||
std::vector<p2t::Point*> hole;
|
||||
|
||||
|
|
|
@ -194,7 +194,7 @@ void MD5_HASH::md5_init(MD5_CTX *ctx)
|
|||
|
||||
void MD5_HASH::md5_update(MD5_CTX *ctx, uint8_t data[], uint32_t len)
|
||||
{
|
||||
uint32_t t,i;
|
||||
uint32_t i;
|
||||
|
||||
for (i=0; i < len; ++i) {
|
||||
ctx->data[ctx->datalen] = data[i];
|
||||
|
|
|
@ -97,8 +97,6 @@ void ZONE_FILLER::Fill( std::vector<ZONE_CONTAINER*> aZones )
|
|||
// Remove segment zones
|
||||
m_board->m_Zone.DeleteAll();
|
||||
|
||||
int ii;
|
||||
|
||||
for( auto zone : aZones )
|
||||
{
|
||||
// Keepout zones are not filled
|
||||
|
@ -110,9 +108,7 @@ void ZONE_FILLER::Fill( std::vector<ZONE_CONTAINER*> aZones )
|
|||
toFill.push_back( l );
|
||||
}
|
||||
|
||||
int zoneCount = m_board->GetAreaCount();
|
||||
|
||||
for( int i = 0; i < toFill.size(); i++ )
|
||||
for( unsigned i = 0; i < toFill.size(); i++ )
|
||||
{
|
||||
if( m_commit )
|
||||
{
|
||||
|
@ -142,7 +138,7 @@ void ZONE_FILLER::Fill( std::vector<ZONE_CONTAINER*> aZones )
|
|||
#ifdef USE_OPENMP
|
||||
#pragma omp for schedule(dynamic)
|
||||
#endif
|
||||
for( int i = 0; i < toFill.size(); i++ )
|
||||
for( unsigned i = 0; i < toFill.size(); i++ )
|
||||
{
|
||||
SHAPE_POLY_SET rawPolys, finalPolys;
|
||||
ZONE_SEGMENT_FILL segFill;
|
||||
|
@ -204,7 +200,7 @@ void ZONE_FILLER::Fill( std::vector<ZONE_CONTAINER*> aZones )
|
|||
#ifdef USE_OPENMP
|
||||
#pragma omp for schedule(dynamic)
|
||||
#endif
|
||||
for( int i = 0; i < toFill.size(); i++ )
|
||||
for( unsigned i = 0; i < toFill.size(); i++ )
|
||||
{
|
||||
if( m_progressReporter )
|
||||
{
|
||||
|
@ -228,7 +224,7 @@ void ZONE_FILLER::Fill( std::vector<ZONE_CONTAINER*> aZones )
|
|||
}
|
||||
else
|
||||
{
|
||||
for( int i = 0; i < toFill.size(); i++ )
|
||||
for( unsigned i = 0; i < toFill.size(); i++ )
|
||||
{
|
||||
connectivity->Update( toFill[i].m_zone );
|
||||
}
|
||||
|
|
|
@ -53,7 +53,10 @@ bool BOARD::OnAreaPolygonModified( PICKED_ITEMS_LIST* aModifiedZonesList,
|
|||
bool modified = NormalizeAreaPolygon( aModifiedZonesList, modified_area );
|
||||
|
||||
// now see if we need to clip against other areas
|
||||
/*
|
||||
LAYER_NUM layer = modified_area->GetLayer();
|
||||
*/
|
||||
|
||||
bool bCheckAllAreas = TestAreaIntersections( modified_area );
|
||||
|
||||
if( bCheckAllAreas )
|
||||
|
|
|
@ -57,7 +57,7 @@ struct Point {
|
|||
std::vector<Edge*> edge_list;
|
||||
|
||||
/// Construct using coordinates.
|
||||
Point(double x, double y) : x(x), y(y) {}
|
||||
Point(double ax, double ay) : x(ax), y(ay) {}
|
||||
|
||||
/// Set this point to all zeros.
|
||||
void set_zero()
|
||||
|
|
|
@ -789,7 +789,7 @@ void Sweep::FlipScanEdgeEvent(SweepContext& tcx, Point& ep, Point& eq, Triangle&
|
|||
Sweep::~Sweep() {
|
||||
|
||||
// Clean up memory
|
||||
for(int i = 0; i < nodes_.size(); i++) {
|
||||
for(unsigned i = 0; i < nodes_.size(); i++) {
|
||||
delete nodes_[i];
|
||||
}
|
||||
|
||||
|
|
|
@ -217,27 +217,27 @@ BOARD* loadBoard( const std::string& filename )
|
|||
return brd;
|
||||
}
|
||||
|
||||
int main(int argc, char *argv[])
|
||||
int main( int argc, char *argv[] )
|
||||
{
|
||||
auto brd = loadBoard( argc > 1 ? argv[1] : "../../../../tests/dp.kicad_pcb");
|
||||
auto brd = loadBoard( argc > 1 ? argv[1] : "../../../../tests/dp.kicad_pcb" );
|
||||
|
||||
if(!brd)
|
||||
return -1;
|
||||
if( !brd )
|
||||
return -1;
|
||||
|
||||
|
||||
PROF_COUNTER cnt("allBoard");
|
||||
PROF_COUNTER cnt( "allBoard" );
|
||||
|
||||
|
||||
#pragma omp parallel for schedule(dynamic)
|
||||
for( int z = 0; z<brd->GetAreaCount(); z++)
|
||||
for( int z = 0; z<brd->GetAreaCount(); z++ )
|
||||
{
|
||||
auto zone = brd->GetArea(z);
|
||||
auto zone = brd->GetArea( z );
|
||||
SHAPE_POLY_SET poly = zone->GetFilledPolysList();
|
||||
|
||||
poly.CacheTriangulation();
|
||||
|
||||
(void) poly;
|
||||
printf("zone %d/%d\n", (z+1), brd->GetAreaCount() );
|
||||
printf("zone %d/%d\n", ( z+1 ), brd->GetAreaCount() );
|
||||
#if 0
|
||||
PROF_COUNTER unfrac("unfrac");
|
||||
poly.Unfracture( SHAPE_POLY_SET::PM_FAST );
|
||||
|
|
Loading…
Reference in New Issue