From 6f935405883c909eab767dfedecb3b03e51cde6d Mon Sep 17 00:00:00 2001 From: Petr Baudis Date: Wed, 21 Mar 2012 23:15:30 +0100 Subject: [PATCH] feature_payloads(): Take pattern_setup inst. of pattern_config as first parameter --- pattern.c | 6 +++--- pattern.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pattern.c b/pattern.c index 380044d..30e8d54 100644 --- a/pattern.c +++ b/pattern.c @@ -82,15 +82,15 @@ feature_name(enum feature_id f) } int -feature_payloads(struct pattern_config *pc, enum feature_id f) +feature_payloads(struct pattern_setup *pat, enum feature_id f) { switch (f) { case FEAT_SPATIAL: assert(features[f].payloads < 0); - return pc->spat_dict->nspatials; + return pat->pc.spat_dict->nspatials; case FEAT_BORDER: assert(features[f].payloads < 0); - return pc->bdist_max + 1; + return pat->pc.bdist_max + 1; default: assert(features[f].payloads > 0); return features[f].payloads; diff --git a/pattern.h b/pattern.h index d8103a0..94c3310 100644 --- a/pattern.h +++ b/pattern.h @@ -152,7 +152,7 @@ char *str2feature(char *str, struct feature *f); /* Get name of given feature. */ char *feature_name(enum feature_id f); /* Get number of possible payload values associated with the feature. */ -int feature_payloads(struct pattern_config *pc, enum feature_id f); +int feature_payloads(struct pattern_setup *pat, enum feature_id f); /* Append pattern as feature spec string. */ char *pattern2str(char *str, struct pattern *p); -- 2.11.4.GIT