car-samples icon indicating copy to clipboard operation
car-samples copied to clipboard

NavigationTemplate doesn't show the map. Black screen

Open artrobert opened this issue 3 years ago • 3 comments

Hi, I am playing with the automotive library and I managed to run all the examples and created a project with the templates.

I noticed that using the PlaceListMapTemplate displays the map but when i try using the NavigationTemplate the screen is black (other actions and buttons appear) but only the map is not showing.

I tried to do this simple example on Polestar2:

class NavigationMap(carContext: CarContext) : Screen(carContext) { override fun onGetTemplate(): Template { val actionStrip = ActionStrip.Builder() .addAction( Action.Builder() .setTitle("BACK") .setOnClickListener { this.finish() } .build()) .build() return NavigationTemplate.Builder() .setActionStrip(actionStrip) .setBackgroundColor(CarColor.SECONDARY) .build() } }

Is is something that I am not doing right or missing a KEY for the map or donno? The examples are using a PNG drawn map and is not that obvious what is wrong.

artrobert avatar Feb 28 '22 08:02 artrobert

@artrobert same here, did you find a solution?

anderlopz avatar May 30 '22 11:05 anderlopz

@artrobert did you find any solution?

TanviJani avatar Apr 07 '23 05:04 TanviJani