简体   繁体   中英

Error: No matching function for call to when using GeoDataPlacemark::setStyle

I am using marble with qt5 and I am getting this error message when executing these lines of code. Any Idea?(Can it be that I am missing any packages?) Thanks!

styleArch = new Marble::GeoDataStyle;
        styleArch->setIconStyle( *icon );
        place->setStyle( styleArch );

错误图片

The API changed from pointers to shared pointers. This should work:

styleArch = new Marble::GeoDataStyle;
styleArch->setIconStyle( *icon );
place->setStyle( Marble::GeoDataStyle::Ptr( styleArch ) );

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM