Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.4k views
in Technique[技术] by (71.8m points)

unreal engine4 - CARLA - Create Custom semantic tags Does not work

i followed the instructions on Create semantic tags to create my custom tags.

  1. I created two new folders, ChevronSign and YellowLine
  2. Then i added the tags to ObjectLabel.h in LibCarla/source/carla/rpc
  3. Then i edited Tagger.cpp in Unreal/CarlaUE4/Plugins/Carla/Source/Carla/Game
  4. And finally defined a color code in CityScapesPalette.h in LibCarla/source/carla/image.

I moved the assets in the according directory, and they appear black, so no label. Moving the assets in one of the default folders works just fine, the semantic tag gets displayed correct.

What i tried:

  1. I changed the color of a default label and checked if the color would change. It did not.
  2. I tried to rebuild carla with make CarlaUE4Editor, and an error because of the new tags:
/carla/Unreal/CarlaUE4/Plugins/Carla/Source/Carla/Game/Tagger.cpp:48:67: error: no member named 'ChevronSign' in 'carla::rpc::CityObjectLabel'
  else if (String == "ChevronSign")  return crp::CityObjectLabel::ChevronSign;

/carla/Unreal/CarlaUE4/Plugins/Carla/Source/Carla/Game/Tagger.cpp:49:67: error: no member named 'YellowLine' in 'carla::rpc::CityObjectLabel'
  else if (String == "YellowLine")   return crp::CityObjectLabel::YellowLine;
  1. So i checked if there are other ObjectLabel.h files in my system and customized all of them as the first one. I found 3 of them. enter image description here

Then the i ran make CarlaUE4Editor sucessfully. But the Semantic Tags still don't work.

Does anyone know which mistake i made? Is there a mistake in the documentation?

Thanks in advance!

question from:https://stackoverflow.com/questions/65647171/carla-create-custom-semantic-tags-does-not-work

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

I found the mistake. I just had to upgrade from carla 0.9.9 to 0.9.10.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...