Repository navigation
Conversation
|
Why did you remove the motorider-dark theme when there is no alternative?? |
|
@Sublimis Because we would need to maintain it upstream. If you need it, I think @MotoUKRider still updates it here: Anyway there is a better and global alternative that works on all themes: See an example for grayscale in ColorFilterMapViewer sample. |
|
Not sure I get the point. The simplest way to simulate a "dark theme" is to do the color inversion... But the exact algorithm is not the point. The point is that there is no real alternative to a dedicated dark theme, and that the |
|
This was the code to invert colors, for completeness: displayModel.setThemeCallback(new ThemeCallback()
{
final Paint mPaint = new Paint();
final ColorFilter mColorFilter = new ColorMatrixColorFilter(new float[]{
-1, 0, 0, 0, 255, 0, -1, 0, 0, 255, 0, 0, -1, 0, 255, 0, 0,
0, 1, 0});
@Override
public Bitmap getBitmap(final Bitmap bitmap)
{
mPaint.setColorFilter(mColorFilter);
android.graphics.Bitmap immutable = AndroidGraphicFactory.getBitmap(bitmap);
android.graphics.Bitmap mutable = immutable.copy(android.graphics.Bitmap.Config.ARGB_8888, true);
Canvas androidCanvas = new Canvas(mutable);
androidCanvas.drawBitmap(mutable, 0, 0, mPaint);
return new AndroidBitmap(mutable);
}
@Override
public int getColor(final RenderInstruction origin, final int color)
{
return Color.argb(Color.alpha(color), -Color.red(color) + 255, -Color.green(color) + 255, -Color.blue(color) + 255);
}
@Override
public String getText(PointOfInterest poi, String text)
{
return text;
}
@Override
public String getText(PolylineContainer way, String text)
{
return text;
}
}); |
|
Here's an idea: Maybe a script could be made that will generate |
|
@Sublimis Motorider + Biker themes are maintained in both VTM + Mapsforge
Now only the 2 Motorider themes have a dark version:
We can ask @MotoUKRider if he can create dark versions, but for all 4 themes. Then if all 4 themes have a dark version, we could include them in repositories. |
|
@Sublimis Also the dark theme zip now contains 2 dark themes: dark and indigo. So all dark versions are x2 and so it's their maintenance by @MotoUKRider. |
|
@Sublimis As I understand, Cruiser never had a "Dark" theme until I wrote one for @devemux86 which was included in previous App builds, but has since been removed. The idea was to take the default/normal "Light" theme and simply tame the colours for night-time use. I also included an "Indigo" version as several other Apps have that style, and I personally prefer it. The above themes are all based on the "Biker" theme that Cruiser used which, according to my older files, contained around 1200 lines. We're now at 2200 so there's a considerable difference to what we had a year ago. New rules, improved sequential rendering (ie: thin hair-lines at zoom-n, then a normal road at zoom-n+1) and the "Layers" menu for the POIs/features. There's been many (on+off-list) discussions about theme XMLs, versions, and keeping them "in sync" with each other. The idea is to offer a couple of general use map styles and the really keen user has the ability to load their own. The "Biker" theme has been tweaked slightly to resemble OpenStreetMap and the "Motorider" Default/Light theme I styled for UK roads. I'm not an App-coder (or a historian, so forgive any errors), and can't comment or help with the API calls, but the theme XMLs are all in-sync so can be re-added. I think I left out a dedicated "Biker at Night" theme because when it's dark, nobody would notice 🤡 |
|
I will add the Dark and Indigo map themes in both repositories. |
|
Thanks @devemux86 @MotoUKRider, new dark themes work great. However the latest update changed hill shading color from It would probably be best to darken the contour lines for dark themes, and lighten the hill shading a bit?
|
|
@Sublimis Old hillshading color was too light and in dark themes the rendering was not nice. If current hillshading color is too dark, |
Why not also darken the contour lines a bit? In Biker light theme the contour lines are all like |
|
@Sublimis About the contour line color in dark themes, @MotoUKRider can also see it. |
|
There is a marked difference between the contour lines' visibility depending upon whether hillshading is enabled. Simply by turning it on/off as well as varying the intensity alters how clear they are. It's going to be tricky finding a happy medium but I can certainly make them consistent across the map "engine" types (they may need to vary between light/dark). So, in short, from tests - it's very easy to make a "Dark" map with full-intensity hillshading have nice contour-lines, but if you then turn off the shading, the lines are very "visible". It's a lot of detail to worry about in what is, essentially, a night-time navigation theme 🌃 🌙 |
|
Also, hillshading is mainly intended for light themes. Dark themes are most useful in navigation, where hillshading has little use. |
|
@devemux86 @MotoUKRider Thus it would be enough to simplify things and just leave the contour lines color as is in the light theme ( This is what was already said earlier. To illustrate, here is the Indigo theme with contour lines made
On the first image the hill shading is Maybe the hill shading could be made something like
|
|
Agreed, let's use the same contour line color About the hillshading color in dark themes, I think the |
|
Simple online edits, best made by someone who can see the changes within their development tools. |
|
I pushed the changes in the 2 dark themes. |








No description provided.