コード例 #1
0
ファイル: io.cpp プロジェクト: dschult/sogen
/* read_pipe reads the maximum score and the received score from the given pipe
	parameters:
		fd: the file descriptor of the pipe to write to
		max_score: a pointer to store the maximum score the simulation could have received
		score: a pointer to store the score the simulation actually received
	returns: nothing
	notes:
	todo:
*/
void read_pipe (int fd, double* max_score, double* score) {
	read_pipe_int(fd, max_score);
	read_pipe_int(fd, score);
}
コード例 #2
0
ファイル: io.cpp プロジェクト: havu73/circulating_clock_2014
/* read_pipe reads the maximum score and the received score from the given pipe
	parameters:
		fd: the file descriptor of the pipe to write to
		max_score: a pointer to store the maximum score the simulation could have received
		score: a pointer to store the score the simulation actually received
	returns: nothing
	notes:
	todo:
*/
void read_pipe (int fd, double** score) {
	for (int i = 0; i < ip.num_sets; i ++){
		read_pipe_int(fd, score[i]);
	}
}
コード例 #3
0
ファイル: io.cpp プロジェクト: CarltonYang/sogen_2016_718
/* read_pipe reads the maximum score and the received score from the given pipe
	parameters:
		fd: the file descriptor of the pipe to write to
		max_score: a pointer to store the maximum score the simulation could have received
		score: a pointer to store the score the simulation actually received
	returns: nothing
	notes:
	todo:
*/
void read_pipe (int fd, int* max_score, int scores[], int num_sets) {
	read_pipe_int(fd, max_score);
	for (int i = 0; i < num_sets; i++) {
		read_pipe_int(fd, &(scores[i]));
	}
}
コード例 #4
0
ファイル: io.cpp プロジェクト: aylab/sres-sampler2
/* read_pipe reads the maximum score and the received score from the given pipe
	parameters:
		fd: the file descriptor of the pipe to write to
		max_score: a pointer to store the maximum score the simulation could have received
		score: a pointer to store the score the simulation actually received
	returns: nothing
	notes:
	todo:
*/
void read_pipe (int fd, int* max_score, int* score) {
	read_pipe_int(fd, max_score);
	read_pipe_int(fd, score);
}