我想用光线着色器制作3D贴图。我看过这个网页https://www.tylermw.com/3d-ggplots-with-rayshader/用我的数据尝试代码。在这个网页中,高度图是黑色的,但我的输出上没有。有什么办法得到这样的结果吗?谢谢
我使用这个代码。
map <- sf::st_read('map/map.shp', quiet = TRUE) gg = ggplot(map) + geom_sf(aes(fill =AREA),linewidth=0.7,colour='black',inherit.aes=FALSE) + scale_fill_viridis('Area',na.value = 'white')+ theme(axis.line = element_blank(),axis.title = element_blank(), axis.ticks = element_blank(), axis.text = element_blank()) plot_gg(gg, multicore = TRUE, width = 6 ,height=2.7, fov = 70,offset_edges = TRUE)