|
@@ -92,7 +92,10 @@ ImageHolder::drawBoundingBoxes(
|
|
|
for (int i = 0; i < list_bounding_box_->size(); i++) {
|
|
|
int labelID = list_bounding_box_->at(i).label_ID_;
|
|
|
|
|
|
- aPen->setColor(QColor(list_label_color_->at(labelID)));
|
|
|
+ if (labelID < list_label_color_->count())
|
|
|
+ aPen->setColor(QColor(list_label_color_->at(labelID)));
|
|
|
+ else
|
|
|
+ aPen->setColor(QColor(Qt::white));
|
|
|
|
|
|
/* checking whether labeled area is of main object or not */
|
|
|
if (labelID == *main_label_)
|