Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Oleksii Turkot
CrystFEL
Commits
14d12aa5
Commit
14d12aa5
authored
Mar 16, 2011
by
Thomas White
Browse files
--record=peaksifnotindexed option
parent
193c900d
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/indexamajig.c
View file @
14d12aa5
...
...
@@ -132,17 +132,20 @@ static void show_help(const char *s)
"
\n\n
"
"You can control what information is included in the output stream using
\n
"
"' --record=<flags>'. Possible flags are:
\n\n
"
" pixels Include a list of sums of pixel values within the
\n
"
" integration domain, correcting for individual pixel
\n
"
" solid angles.
\n
"
" pixels
Include a list of sums of pixel values within the
\n
"
"
integration domain, correcting for individual pixel
\n
"
"
solid angles.
\n
"
"
\n
"
" integrated Include a list of reflection intensities, produced by
\n
"
" integrating around predicted peak locations.
\n
"
" integrated
Include a list of reflection intensities, produced by
\n
"
"
integrating around predicted peak locations.
\n
"
"
\n
"
" peaks Include peak locations and intensities from the peak search.
\n
"
" peaks Include peak locations and intensities from the peak
\n
"
" search.
\n
"
"
\n
"
" peaksifindexed As 'peaks', but only if the pattern could be indexed.
\n
\n
"
" peaksifindexed
As 'peaks', but only if the pattern could be indexed.
\n
"
"
\n
"
" peaksifnotindexed As 'peaks', but only if the pattern could NOT be indexed.
\n
"
"
\n\n
"
"The default is '--record=integrated'. The flags 'pixels' and 'integrated'
\n
"
"are mutually exclusive, as are the flags 'peaks' and 'peaksifindexed'.
\n
"
"
\n\n
"
...
...
src/stream.c
View file @
14d12aa5
...
...
@@ -69,6 +69,10 @@ int parse_stream_flags(const char *a)
exclusive
(
"peaks"
,
"peaksifindexed"
);
return
-
1
;
}
if
(
ret
&
STREAM_PEAKS_IF_NOT_INDEXED
)
{
exclusive
(
"peaks"
,
"peaksifnotindexed"
);
return
-
1
;
}
ret
|=
STREAM_PEAKS
;
}
else
if
(
strcmp
(
flags
[
i
],
"peaksifindexed"
)
==
0
)
{
...
...
@@ -76,8 +80,25 @@ int parse_stream_flags(const char *a)
exclusive
(
"peaks"
,
"peaksifindexed"
);
return
-
1
;
}
if
(
ret
&
STREAM_PEAKS_IF_NOT_INDEXED
)
{
exclusive
(
"peaksifnotindexed"
,
"peaksifindexed"
);
return
-
1
;
}
ret
|=
STREAM_PEAKS_IF_INDEXED
;
}
else
if
(
strcmp
(
flags
[
i
],
"peaksifnotindexed"
)
==
0
)
{
if
(
ret
&
STREAM_PEAKS
)
{
exclusive
(
"peaks"
,
"peaksifnotindexed"
);
return
-
1
;
}
if
(
ret
&
STREAM_PEAKS_IF_INDEXED
)
{
exclusive
(
"peaksifnotindexed"
,
"peaksifindexed"
);
return
-
1
;
}
ret
|=
STREAM_PEAKS_IF_NOT_INDEXED
;
}
else
{
ERROR
(
"Unrecognised stream flag '%s'
\n
"
,
flags
[
i
]);
return
0
;
...
...
@@ -267,7 +288,9 @@ void write_chunk(FILE *ofh, struct image *i, int f)
J_to_eV
(
ph_lambda_to_en
(
i
->
lambda
)));
if
(
(
f
&
STREAM_PEAKS
)
||
((
f
&
STREAM_PEAKS_IF_INDEXED
)
&&
(
i
->
indexed_cell
!=
NULL
))
)
{
||
((
f
&
STREAM_PEAKS_IF_INDEXED
)
&&
(
i
->
indexed_cell
!=
NULL
))
||
((
f
&
STREAM_PEAKS_IF_NOT_INDEXED
)
&&
(
i
->
indexed_cell
==
NULL
))
)
{
fprintf
(
ofh
,
"
\n
"
);
write_peaks
(
i
,
ofh
);
}
...
...
src/stream.h
View file @
14d12aa5
...
...
@@ -22,11 +22,12 @@ struct image;
/* Possible options dictating what goes into the output stream */
enum
{
STREAM_NONE
=
0
,
STREAM_INTEGRATED
=
1
<<
0
,
STREAM_PIXELS
=
1
<<
1
,
STREAM_PEAKS
=
1
<<
2
,
STREAM_PEAKS_IF_INDEXED
=
1
<<
3
,
STREAM_NONE
=
0
,
STREAM_INTEGRATED
=
1
<<
0
,
STREAM_PIXELS
=
1
<<
1
,
STREAM_PEAKS
=
1
<<
2
,
STREAM_PEAKS_IF_INDEXED
=
1
<<
3
,
STREAM_PEAKS_IF_NOT_INDEXED
=
1
<<
4
,
};
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment