displaying subframe index in gui

This commit is contained in:
Dhanya Maliakal 2015-09-23 11:50:47 +02:00
parent 754d0b7911
commit 2ed8b46ad0
2 changed files with 10 additions and 6 deletions

View File

@ -229,10 +229,10 @@ int ResetDaqForGui();
static void* DataStartAcquireThread(void *this_pointer);
/** This is called by the detector class to copy the data it jus acquired */
static int GetDataCallBack(detectorData *data, int fIndex, void *this_pointer);
static int GetDataCallBack(detectorData *data, int fIndex, int subIndex, void *this_pointer);
/** This is called by the GetDataCallBack function to copy the data */
int GetData(detectorData *data, int fIndex);
int GetData(detectorData *data, int fIndex, int subIndex);
/** This is called by detector class when acquisition is finished
* @param currentProgress current progress of measurement

View File

@ -735,8 +735,8 @@ void* qDrawPlot::DataStartAcquireThread(void *this_pointer){
//-------------------------------------------------------------------------------------------------------------------------------------------------
int qDrawPlot::GetDataCallBack(detectorData *data, int fIndex, void *this_pointer){
((qDrawPlot*)this_pointer)->GetData(data,fIndex);
int qDrawPlot::GetDataCallBack(detectorData *data, int fIndex, int subIndex, void *this_pointer){
((qDrawPlot*)this_pointer)->GetData(data,fIndex, subIndex);
return 0;
}
@ -744,10 +744,11 @@ int qDrawPlot::GetDataCallBack(detectorData *data, int fIndex, void *this_pointe
//-------------------------------------------------------------------------------------------------------------------------------------------------
int qDrawPlot::GetData(detectorData *data,int fIndex){
int qDrawPlot::GetData(detectorData *data,int fIndex, int subIndex){
#ifdef VERYVERBOSE
cout << "******Entering GetDatafunction********" << endl;
cout << "fIndex " << fIndex << endl;
cout << "subIndex " << subIndex << endl;
cout << "fname " << data->fileName << endl;
cout << "npoints " << data->npoints << endl;
cout << "npy " << data->npy << endl;
@ -775,11 +776,14 @@ int qDrawPlot::GetData(detectorData *data,int fIndex){
if(fIndex!=-1){
currentFrameIndex=fIndex;
sprintf(temp_title,"#%d",fIndex);
if((myDet->getDetectorsType()==slsDetectorDefs::EIGER) && (subIndex != -1))
sprintf(temp_title,"#%d %d",fIndex,subIndex);
}else{
if(fileSaveEnable) strcpy(temp_title,"#%d");
else sprintf(temp_title,"",currentFrame);
}
if(subIndex != -1)
sprintf(temp_title,"#%d %d",fIndex,subIndex);
//Plot Disabled
if(!plotEnable) return 0;