ShowFreeHandWaveDlg Example for C++ 5.0 and later
void CDialogs::OnShowFreeHandWaveDlg()
{
int nRet = 0;
m_pRasterImageEfxDlg->ScaleValue = 10;
m_pRasterImageEfxDlg->WaveLength= 5;
m_pRasterImageEfxDlg->ImageEffectFlags = FILL_CLR | DIS_FRQ;
m_pRasterImageEfxDlg->Angle= 4500;
m_pRasterImageEfxDlg->FillColor= RGB ( 200, 0, 0 );
m_pRasterImageEfxDlg->UIFlags = FREEHANDWAVE_SHOW_PREVIEW |
FREEHANDWAVE_SHOW_TOOL_ZOOMLEVEL;
m_pRasterImageEfxDlg->Bitmap = m_LeadRasterView.GetRaster ().GetBitmap
();
nRet= m_pRasterImageEfxDlg->ShowFreeHandWaveDlg((long)this->m_hWnd);
if (nRet == 0 && m_pRasterImageEfxDlg->DialogStatus == DLG_OK)
{
m_pRasterProc->AmplitudesCount= m_pRasterImageEfxDlg->AmplitudesCount;
for (int i= 0; i < m_pRasterImageEfxDlg->AmplitudesCount; i ++ )
{
m_pRasterProc->PutAmplitudes(i,m_pRasterImageEfxDlg->GetAmplitudes(i));
}
m_pRasterProc->FreeHandWave (m_LeadRasterView.GetRaster (),
m_pRasterImageEfxDlg->ScaleValue,
m_pRasterImageEfxDlg->WaveLength,
m_pRasterImageEfxDlg->Angle,
m_pRasterImageEfxDlg->FillColor,
m_pRasterImageEfxDlg->ImageEffectFlags );
}
}