Exclude specific segment when calling HTK_Write_Stream_File

Below is sample code on how to exclude specific segment when your exporting to HSF file.

static HC_KEY excludeSeg;

void CSolidHoopsView::OnExtraSlot1()
{
    HC_Open_Segment_By_Key(m_pHView->GetModelKey()); {
        HC_Open_Segment("a"); {
        } HC_Close_Segment();
        excludeSeg = HC_Open_Segment("b"); {
              HPoint	spts[4];
                  int		facelist[5];
                  
                  spts[0].x = -0.5f; spts[0].y =  -0.5f; spts[0].z =  0.0f;
                  spts[1].x = 0.5f; spts[1].y =  -0.5f; spts[1].z =  0.0f;
                  spts[2].x = 0.5f; spts[2].y =  0.5f; spts[2].z =  0.0f;
                  spts[3].x = -0.5f; spts[3].y =  0.5f; spts[3].z =  0.0f;
                  
                  facelist[0]  = 4; facelist[1]  = 0; facelist[2]  = 1; facelist[3] = 2;
                  facelist[4]  = 3;
                  
                  
                  HC_Insert_Shell (4, spts, 5, facelist);
        } HC_Close_Segment();

    } HC_Close_Segment();

    m_pHView->Update();


    m_pHView->Update();

    HStreamFileToolkit tk;
    tk.AddExcludedSegment(excludeSeg);
    //tk.AddExcludedSegments();
    
    HC_Open_Segment_By_Key(m_pHView->GetModelKey()); {
        HTK_Write_Stream_File("D:/SDHV/21353/skip_segment.hsf", &tk);
    } HC_Close_Segment();

    m_pHView->Update();
}