예제 #1
0
/*!
 * Saves \a rayLists data into the database.
 */
void PhotonMapExportDB::SavePhotonMap( std::vector< Photon* > raysLists )
{

	if( !m_isDBOpened )	Open();

	if( m_saveCoordinates && m_saveSide && m_savePrevNexID && m_saveSurfaceID )
		SaveAllData( raysLists );
	else if( m_saveCoordinates && m_saveSide && !m_savePrevNexID && m_saveSurfaceID )
		SaveNotNextPrevID( raysLists );
	else
		SaveSelectedData( raysLists );

}
예제 #2
0
파일: Pipe.cpp 프로젝트: uesoft/AutoPFA
BOOL Pipe::Read(PipePerisist *pPerisist)
{
	ms_Name.SetValue(pPerisist->Name());
    ms_StartPt.SetValue1(pPerisist->StartPtX());
	ms_StartPt.SetValue2(pPerisist->StartPtY());
	ms_EndPt.SetValue1(pPerisist->EndPtX());
	ms_EndPt.SetValue2(pPerisist->EndPtY());
	ms_InJun.SetValue(pPerisist->InJunID());
	ms_OutJun.SetValue(pPerisist->OutJunID());
	ms_InDia.SetValue(pPerisist->InDia());
	ms_InDia.SetUnit(pPerisist->InDiaUnit());
	ms_Len.SetValue(pPerisist->Len());
	ms_Len.SetUnit(pPerisist->LenUnit());
	ms_WaveSpeed.SetValue(pPerisist->WaveSpeed());
	ms_WaveSpeed.SetUnit(pPerisist->WaveSpeedUnit());
	ms_Material.SetValue(pPerisist->Material());
	ms_Size.SetValue(pPerisist->Size());
	ms_PipeType.SetValue(pPerisist->PipeType());
	ms_Thick.SetValue(pPerisist->Thick());
	ms_Thick.SetUnit(pPerisist->ThickUnit());
	ms_Elasticity.SetValue(pPerisist->Elasticity());
	ms_Elasticity.SetUnit(pPerisist->ElasticityUnit());
	ms_PossionRatio.SetValue(pPerisist->PossionRatio());
	ms_InDiaReduce.SetValue(pPerisist->InDiaReduce());
	ms_CalcWave.SetValue(pPerisist->CalcWave());
	ms_SupportType.SetValue(pPerisist->SupportType());
	ms_C1.SetValue(pPerisist->C1());
	ms_LossType.SetValue(pPerisist->FrictionModel());
	ms_Friction.SetValue(pPerisist->Friction());
	ms_Friction.SetUnit(pPerisist->FrictionUnit());
	ms_LocalK.SetValue(pPerisist->LocalK());
	ms_PipeFactor.SetValue(pPerisist->PipeFactor());
	ms_FitFactor.SetValue(pPerisist->FitFactor());
	ms_InitFlow.SetData(pPerisist->InitFlow());
	ms_SectionNum.SetValue(pPerisist->SectionNum());
	ms_ParaNum.SetValue(pPerisist->ParaNum());
	ms_PartFull.SetValue(pPerisist->PartFull());
	SetB(pPerisist->B());
	SaveAllData();
	return TRUE;
}