@@ -85,6 +85,7 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
85
85
declareParam<int >(
86
86
encode_speed_paramDescriptor.name , config_.encode_speed ,
87
87
encode_speed_paramDescriptor);
88
+ getParam<int >(encode_speed_paramDescriptor.name , config_.encode_speed );
88
89
89
90
rcl_interfaces::msg::ParameterDescriptor decode_speed_paramDescriptor;
90
91
decode_speed_paramDescriptor.name = " decode_speed" ;
@@ -99,6 +100,7 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
99
100
declareParam<int >(
100
101
decode_speed_paramDescriptor.name , config_.decode_speed ,
101
102
decode_speed_paramDescriptor);
103
+ getParam<int >(decode_speed_paramDescriptor.name , config_.decode_speed );
102
104
103
105
rcl_interfaces::msg::ParameterDescriptor encode_method_paramDescriptor;
104
106
encode_method_paramDescriptor.name = " encode_method" ;
@@ -113,13 +115,15 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
113
115
declareParam<int >(
114
116
encode_method_paramDescriptor.name , config_.encode_method ,
115
117
encode_method_paramDescriptor);
118
+ getParam<int >(encode_method_paramDescriptor.name , config_.encode_method );
116
119
117
120
rcl_interfaces::msg::ParameterDescriptor deduplicate_paramDescriptor;
118
121
deduplicate_paramDescriptor.name = " deduplicate" ;
119
122
deduplicate_paramDescriptor.type = rcl_interfaces::msg::ParameterType::PARAMETER_BOOL;
120
123
deduplicate_paramDescriptor.description =
121
124
" Remove duplicate point entries." ;
122
125
declareParam<bool >(deduplicate_paramDescriptor.name , true , deduplicate_paramDescriptor);
126
+ getParam<bool >(deduplicate_paramDescriptor.name , config_.deduplicate );
123
127
124
128
rcl_interfaces::msg::ParameterDescriptor force_quantization_paramDescriptor;
125
129
force_quantization_paramDescriptor.name = " force_quantization" ;
@@ -130,6 +134,7 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
130
134
declareParam<bool >(
131
135
force_quantization_paramDescriptor.name , config_.force_quantization ,
132
136
force_quantization_paramDescriptor);
137
+ getParam<bool >(force_quantization_paramDescriptor.name , config_.force_quantization );
133
138
134
139
rcl_interfaces::msg::ParameterDescriptor quantization_POSITION_paramDescriptor;
135
140
quantization_POSITION_paramDescriptor.name = " quantization_POSITION" ;
@@ -143,8 +148,9 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
143
148
.set__to_value (31 )
144
149
.set__step (1 )});
145
150
declareParam<int >(
146
- quantization_POSITION_paramDescriptor.name , config_.quantization_NORMAL ,
151
+ quantization_POSITION_paramDescriptor.name , config_.quantization_POSITION ,
147
152
quantization_POSITION_paramDescriptor);
153
+ getParam<int >(quantization_POSITION_paramDescriptor.name , config_.quantization_POSITION );
148
154
149
155
rcl_interfaces::msg::ParameterDescriptor quantization_NORMAL_paramDescriptor;
150
156
quantization_NORMAL_paramDescriptor.name = " quantization_NORMAL" ;
@@ -157,8 +163,9 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
157
163
.set__to_value (31 )
158
164
.set__step (1 )});
159
165
declareParam<int >(
160
- quantization_NORMAL_paramDescriptor.name , config_.quantization_COLOR ,
166
+ quantization_NORMAL_paramDescriptor.name , config_.quantization_NORMAL ,
161
167
quantization_NORMAL_paramDescriptor);
168
+ getParam<int >(quantization_NORMAL_paramDescriptor.name , config_.quantization_NORMAL );
162
169
163
170
rcl_interfaces::msg::ParameterDescriptor quantization_COLOR_paramDescriptor;
164
171
quantization_COLOR_paramDescriptor.name = " quantization_COLOR" ;
@@ -171,8 +178,9 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
171
178
.set__to_value (31 )
172
179
.set__step (1 )});
173
180
declareParam<int >(
174
- quantization_COLOR_paramDescriptor.name , config_.quantization_TEX_COORD ,
181
+ quantization_COLOR_paramDescriptor.name , config_.quantization_COLOR ,
175
182
quantization_COLOR_paramDescriptor);
183
+ getParam<int >(quantization_COLOR_paramDescriptor.name , config_.quantization_COLOR );
176
184
177
185
rcl_interfaces::msg::ParameterDescriptor quantization_TEX_COORD_paramDescriptor;
178
186
quantization_TEX_COORD_paramDescriptor.name = " quantization_TEX_COORD" ;
@@ -186,8 +194,9 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
186
194
.set__to_value (31 )
187
195
.set__step (1 )});
188
196
declareParam<int >(
189
- quantization_TEX_COORD_paramDescriptor.name , config_.quantization_GENERIC ,
197
+ quantization_TEX_COORD_paramDescriptor.name , config_.quantization_TEX_COORD ,
190
198
quantization_TEX_COORD_paramDescriptor);
199
+ getParam<int >(quantization_TEX_COORD_paramDescriptor.name , config_.quantization_TEX_COORD );
191
200
192
201
rcl_interfaces::msg::ParameterDescriptor quantization_GENERIC_paramDescriptor;
193
202
quantization_GENERIC_paramDescriptor.name = " quantization_GENERIC" ;
@@ -201,8 +210,9 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
201
210
.set__to_value (31 )
202
211
.set__step (1 )});
203
212
declareParam<int >(
204
- quantization_GENERIC_paramDescriptor.name , config_.quantization_POSITION ,
213
+ quantization_GENERIC_paramDescriptor.name , config_.quantization_GENERIC ,
205
214
quantization_GENERIC_paramDescriptor);
215
+ getParam<int >(quantization_GENERIC_paramDescriptor.name , config_.quantization_GENERIC );
206
216
207
217
rcl_interfaces::msg::ParameterDescriptor expert_quantization_paramDescriptor;
208
218
expert_quantization_paramDescriptor.name = " expert_quantization" ;
@@ -214,6 +224,7 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
214
224
declareParam<bool >(
215
225
expert_quantization_paramDescriptor.name , config_.expert_quantization ,
216
226
expert_quantization_paramDescriptor);
227
+ getParam<bool >(expert_quantization_paramDescriptor.name , config_.expert_quantization );
217
228
218
229
rcl_interfaces::msg::ParameterDescriptor expert_attribute_types_paramDescriptor;
219
230
expert_attribute_types_paramDescriptor.name = " expert_attribute_types" ;
@@ -225,7 +236,9 @@ void DracoPublisher::declareParameters(const std::string & base_topic)
225
236
declareParam<bool >(
226
237
expert_attribute_types_paramDescriptor.name , config_.expert_attribute_types ,
227
238
expert_attribute_types_paramDescriptor);
239
+ getParam<bool >(expert_attribute_types_paramDescriptor.name , config_.expert_attribute_types );
228
240
241
+ // we call get param at runtime to get the latest value for these
229
242
declareParam<std::string>(" attribute_mapping.attribute_type.x" , " POSITION" );
230
243
declareParam<std::string>(" attribute_mapping.attribute_type.y" , " POSITION" );
231
244
declareParam<std::string>(" attribute_mapping.attribute_type.z" , " POSITION" );
0 commit comments