ComponentOne PdfViewer for WPF and Silverlight
C1.WPF.PdfViewer.4.6.2 Assembly / CSJ2K.j2k.entropy.encoder Namespace / CBlkRateDistStats Class / selectConvexHull Method
The rates (in bytes) for each truncation point in the compressed data. This array is modified by the method.
The reduction in distortion (with respect to no information coded) for each truncation point. This array is modified by the method.
An array of boolean flags indicating, for each pass, if a pass is terminated or not (true if terminated). If null then it is assumed that no pass is terminated except the last one which always is.
The number of truncation points contained in 'rates', 'dist' and 'termp'.
If false the convex hull is constructed as for lossy coding. If true it is constructed as for lossless coding, in which case it is ensured that all bit-planes are sent (i.e. the last truncation point is always included).

In This Topic
    selectConvexHull Method
    In This Topic
    Compute the rate-distorsion slopes and selects those that lie in a convex hull. It will compute the slopes, select the ones that form the convex hull and initialize the 'truncIdxs' and 'truncSlopes' arrays, as well as 'nVldTrunc', with the selected truncation points. It will also initialize 'truncRates' and 'isTermPass' arrays, as well as 'nTotTrunc', with all the truncation points (selected or not).

    Note that the arrays 'rates' and 'termp' are copied, not referenced, so they can be modified after a call to this method.

    Syntax
    'Declaration
     
    
    Public Overridable Sub selectConvexHull( _
       ByVal rates() As Integer, _
       ByVal dists() As Double, _
       ByVal termp() As Boolean, _
       ByVal n As Integer, _
       ByVal inclast As Boolean _
    ) 
    public virtual void selectConvexHull( 
       int[] rates,
       double[] dists,
       bool[] termp,
       int n,
       bool inclast
    )

    Parameters

    rates
    The rates (in bytes) for each truncation point in the compressed data. This array is modified by the method.
    dists
    The reduction in distortion (with respect to no information coded) for each truncation point. This array is modified by the method.
    termp
    An array of boolean flags indicating, for each pass, if a pass is terminated or not (true if terminated). If null then it is assumed that no pass is terminated except the last one which always is.
    n
    The number of truncation points contained in 'rates', 'dist' and 'termp'.
    inclast
    If false the convex hull is constructed as for lossy coding. If true it is constructed as for lossless coding, in which case it is ensured that all bit-planes are sent (i.e. the last truncation point is always included).
    See Also