def make_ccw(points):
        """
        Static method. Returns a counterclock wise ordered sequence of 
        points. If there are any repeated point, the method will raise 
        an error.
        
        Due to the 3D character of the package, the order or the points
        will be tried following this order:
		
            1. z=0 pprojection
            2. x=0 pprojection
            3. y=0 pprojection

        :param points: Points to form a polygon (xyz or xy)
        :type points: ndarray with points (xyz or xy) in rows
        :returns: ccw version of the points.
        :rtype: ndarray (shape=(N, 2 or 3))
        """
        from scipy.spatial import ConvexHull
        from pyny3d.utils import sort_numpy
        
        # Repeated points
        points_aux = sort_numpy(points)
        check = np.sum(np.abs(np.diff(points_aux, axis=0)), axis=1)
        if check.min() == 0: raise ValueError('Repeated point: \n'+str(points))
        
        # Convexity
        hull = None
        for cols in [(0, 1), (1, 2), (0, 2)]:
            try:
                hull = ConvexHull(points[:, cols])
            except:
                pass
            if hull is not None: return points[hull.vertices]
        if hull is None: raise ValueError('Wrong polygon: \n'+str(points))