 	 */
 	__device__
 	void swap_polygon(CudaPolygon& ping, CudaPolygon& pong){
-		CudaPolygon t = ping;
+		
 		ping = pong;
-		pong = t;
+		pong.vertex_nb = 0;
 	}
 
 


		
		
		CudaPolygon current_store = current_polygon;
		//doesn't have the stack?
		index_t to_visit[CUDA_Stack_size];
		index_t to_visit_pos = 0;

			points_save(name, *x_);
			store_filename_counter_++;
		}
		

	}

