Compare commits

..

16 Commits

Author SHA1 Message Date
matheusgomesms
f4eb8628e0 Atualizar generator/maxspeeds_builder.cpp
Signed-off-by: matheusgomesms <matheusgomesms@noreply.codeberg.org>
2025-12-09 21:35:32 +01:00
matheusgomesms
4c715cd2ee Removing maxspeed estimate from generator
Signed-off-by: matheusgomesms <matheusgomesms@noreply.codeberg.org>
2025-12-09 15:04:24 +01:00
Jean-Baptiste
c2bc6c27aa [android] Add warning about speed cameras in settings
Signed-off-by: Jean-Baptiste <jeanbaptiste.charron@outlook.fr>
2025-12-08 18:13:11 +01:00
gekeleda
1095e5dbc3 [android] Consider all system langs for TTS
Signed-off-by: gekeleda <git@davidgekeler.eu>
2025-12-08 15:55:49 +01:00
Leonardo Bishop
a1cbcc5885 [drape] Base zoom level on distance to next turn
This commit changes the auto zoom level behaviour during navigation
to be based off the distance to the next turn, rather than naively
coupling it to the current speed. This will improve the navigation
experience during driving.

Signed-off-by: Leonardo Bishop <me@leonardobishop.net>
2025-12-08 08:31:33 +01:00
Jean-Baptiste
641f2308c6 [android] Remove hardocded height of name text field
Signed-off-by: Jean-Baptiste <jeanbaptiste.charron@outlook.fr>
2025-12-07 18:01:17 +01:00
Konstantin Pastbin
f858ebcce0 [generator] Make Taiwan_North use 5 threads for Index stage
Signed-off-by: Konstantin Pastbin <konstantin.pastbin@gmail.com>
2025-12-07 14:06:13 +07:00
matheusgomesms
eb376f5afc Added missing Portuguese articles
Signed-off-by: matheusgomesms <matheusgomesms@noreply.codeberg.org>
2025-12-06 20:54:14 +01:00
x7z4w
71b47719af [search] Remove stop words
Signed-off-by: x7z4w <x7z4w@noreply.codeberg.org>
2025-12-06 19:43:11 +00:00
Konstantin Pastbin
4f7230fcbe [generator] Clone repos shallowly --depth 1
Signed-off-by: Konstantin Pastbin <konstantin.pastbin@gmail.com>
2025-12-06 08:12:42 +01:00
Konstantin Pastbin
2dafdd4338 [generator] Fix boolean action options handling
Signed-off-by: Konstantin Pastbin <konstantin.pastbin@gmail.com>
2025-12-06 08:12:42 +01:00
Konstantin Pastbin
0237751afe [generator] Fix GENARGS in docker_maps_generator.sh
Signed-off-by: Konstantin Pastbin <konstantin.pastbin@gmail.com>
2025-12-06 08:12:42 +01:00
Jean-Baptiste
e7fb3a2f2c [android] Improve padding of instructions during navigation
Signed-off-by: Jean-Baptiste <jeanbaptiste.charron@outlook.fr>
2025-12-05 22:30:03 +01:00
x7z4w
e08d60bb40 [styles] Fix toilets label
Signed-off-by: x7z4w <x7z4w@noreply.codeberg.org>
2025-12-05 22:11:42 +01:00
Jean-Baptiste
de4252f86c [android] Remove transparent background on textview
Signed-off-by: Jean-Baptiste <jeanbaptiste.charron@outlook.fr>
2025-12-05 21:51:27 +01:00
Jean-Baptiste
9d87d77055 [android] Improve size of bookmarks button
Signed-off-by: Jean-Baptiste <jeanbaptiste.charron@outlook.fr>
2025-12-05 17:53:54 +01:00
60 changed files with 2730 additions and 2710 deletions

View File

@@ -105,17 +105,17 @@ jobs:
run: |
echo "Cloning $FORGEJO_SERVER_URL/$FORGEJO_REPOSITORY branch $FORGEJO_REF_NAME"
cd ~
git clone --recurse-submodules --shallow-submodules -b $FORGEJO_REF_NAME --single-branch $FORGEJO_SERVER_URL/$FORGEJO_REPOSITORY.git comaps
git clone --depth 1 --recurse-submodules --shallow-submodules -b $FORGEJO_REF_NAME --single-branch $FORGEJO_SERVER_URL/$FORGEJO_REPOSITORY.git comaps
- name: Checkout wikiparser repo
shell: bash
run: |
cd ~
git clone https://codeberg.org/comaps/wikiparser.git
git clone --depth 1 --single-branch https://codeberg.org/comaps/wikiparser.git
- name: Checkout subways repo
shell: bash
run: |
cd ~
git clone https://codeberg.org/comaps/subways.git
git clone --depth 1 --single-branch https://codeberg.org/comaps/subways.git
copy-coasts:
# if: inputs.run-copy-coasts

View File

@@ -133,7 +133,6 @@ import com.google.android.material.appbar.MaterialToolbar;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import com.google.android.material.floatingactionbutton.FloatingActionButton;
import com.google.android.material.textview.MaterialTextView;
import java.util.ArrayList;
import java.util.Objects;
@@ -1814,8 +1813,9 @@ public class MwmActivity extends BaseMwmFragmentActivity
return false;
}
private void deliverTtsMessage() {
if(Config.isTtsMessageDelivered())
private void deliverTtsMessage()
{
if (Config.isTtsMessageDelivered())
return;
String navigationStartMessage = getResources().getString(R.string.navigation_start_tts_message);

View File

@@ -18,7 +18,6 @@ import app.organicmaps.R;
import app.organicmaps.maplayer.MapButtonsViewModel;
import app.organicmaps.sdk.Framework;
import app.organicmaps.sdk.Router;
import app.organicmaps.sdk.location.LocationHelper;
import app.organicmaps.sdk.maplayer.traffic.TrafficManager;
import app.organicmaps.sdk.routing.CarDirection;
import app.organicmaps.sdk.routing.RoutingController;
@@ -268,18 +267,16 @@ public class NavigationController implements TrafficManager.TrafficCallback, Nav
private void updateSpeedWidgets(@NonNull final RoutingInfo info)
{
final LocationHelper locationHelper = MwmApplication.from(mFrame.getContext()).getLocationHelper();
final Location location = locationHelper.getSavedLocation();
final Location location = MwmApplication.from(mFrame.getContext()).getLocationHelper().getSavedLocation();
if (location == null)
{
mSpeedLimit.setSpeedLimit(-1, false);
mCurrentSpeed.setCurrentSpeed(-1);
return;
}
final double currentAvgSpeed = locationHelper.getAverageSpeed();
final int fSpeedLimit = StringUtils.nativeFormatSpeed(info.speedLimitMps);
final boolean speedLimitExceeded = fSpeedLimit < StringUtils.nativeFormatSpeed(currentAvgSpeed);
final boolean speedLimitExceeded = fSpeedLimit < StringUtils.nativeFormatSpeed(location.getSpeed());
mSpeedLimit.setSpeedLimit(fSpeedLimit, speedLimitExceeded);
mCurrentSpeed.setCurrentSpeed(currentAvgSpeed);
mCurrentSpeed.setCurrentSpeed(location.getSpeed());
}
}

View File

@@ -1,9 +1,9 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
android:viewportWidth="960"
android:viewportHeight="960">
<path
android:pathData="M19,13H5v-2h14v2z"
android:pathData="M240,520q-17,0 -28.5,-11.5T200,480q0,-17 11.5,-28.5T240,440h480q17,0 28.5,11.5T760,480q0,17 -11.5,28.5T720,520L240,520Z"
android:fillColor="#ffffff"/>
</vector>

View File

@@ -1,9 +1,9 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="24"
android:viewportHeight="24">
android:viewportWidth="960"
android:viewportHeight="960">
<path
android:pathData="M19,13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z"
android:pathData="M440,520L240,520q-17,0 -28.5,-11.5T200,480q0,-17 11.5,-28.5T240,440h200v-200q0,-17 11.5,-28.5T480,200q17,0 28.5,11.5T520,240v200h200q17,0 28.5,11.5T760,480q0,17 -11.5,28.5T720,520L520,520v200q0,17 -11.5,28.5T480,760q-17,0 -28.5,-11.5T440,720v-200Z"
android:fillColor="@android:color/white"/>
</vector>

View File

@@ -24,6 +24,6 @@
android:layout_gravity="center_vertical"
android:fontFamily="@string/robotoMedium"
tools:text="Some text should go here"
android:textAppearance="@style/MwmTextAppearance.Body3"
android:textAppearance="@style/MwmTextAppearance.Body1"
android:textColor="?colorSecondary"/>
</LinearLayout>

View File

@@ -25,7 +25,6 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="start|bottom"
android:background="@android:color/transparent"
android:clickable="true"
android:gravity="start|top"
android:text="@string/category_desc_more"

View File

@@ -4,7 +4,7 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/name"
android:layout_width="match_parent"
android:layout_height="@dimen/editor_height_field"
android:layout_height="wrap_content"
android:animateLayoutChanges="true"
android:gravity="center_vertical"
android:orientation="horizontal">
@@ -14,8 +14,7 @@
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:hint="@string/editor_edit_place_name_hint"
android:textColorHint="?android:textColorSecondary">
android:hint="@string/editor_edit_place_name_hint">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/input"
style="@style/MwmWidget.Editor.FieldLayout.EditText"
@@ -31,5 +30,5 @@
android:background="?selectableItemBackgroundBorderless"
android:padding="@dimen/margin_half_plus"
app:srcCompat="@drawable/ic_close"
app:tint="@color/base_red" />
app:tint="?iconTint" />
</LinearLayout>

View File

@@ -35,10 +35,10 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:maxLines="2"
android:padding="@dimen/margin_quarter"
android:padding="@dimen/margin_half"
android:autoSizeTextType="uniform"
android:autoSizeMinTextSize="19sp"
android:autoSizeMaxTextSize="25sp"
android:autoSizeMaxTextSize="24sp"
android:minHeight="60dp"
android:layout_gravity="center_vertical"
android:gravity="center"

View File

@@ -11,14 +11,14 @@
style="@style/MwmWidget.M3.FAB.MapButton.Zoom"
android:tint="?iconTint"
app:srcCompat="@drawable/ic_plus"
app:shapeAppearanceOverlay="@style/ShapeAppearance.MapButton.Zoom.Minus"
android:layout_marginBottom="@dimen/margin_eighth"
app:shapeAppearance="@style/Widget.MaterialComponents.FloatingActionButton"
android:layout_marginBottom="@dimen/margin_half"
android:contentDescription="@string/zoom_in"/>
<com.google.android.material.floatingactionbutton.FloatingActionButton
android:id="@+id/nav_zoom_out"
style="@style/MwmWidget.M3.FAB.MapButton.Zoom"
android:tint="?iconTint"
app:srcCompat="@drawable/ic_minus"
app:shapeAppearanceOverlay="@style/ShapeAppearance.MapButton.Zoom.Plus"
app:shapeAppearance="@style/Widget.MaterialComponents.FloatingActionButton"
android:contentDescription="@string/zoom_out"/>
</LinearLayout>

View File

@@ -34,8 +34,7 @@
android:textAppearance="?android:attr/textAppearance"
android:gravity="start|top"
android:textColor="?attr/colorSecondary"
android:text="@string/category_desc_more"
android:background="@android:color/transparent"/>
android:text="@string/category_desc_more" />
<include
layout="@layout/item_divider"/>
</LinearLayout>

View File

@@ -23,6 +23,7 @@
<string name="pref_tts_info" translatable="false">TtsInfo</string>
<string name="pref_tts_info_link" translatable="false">TtsInfoLink</string>
<string name="pref_tts_speed_cameras" translatable="false">SpeedCameras</string>
<string name="pref_tts_speed_cameras_info" translatable="false">SpeedCamerasInfo</string>
<string name="prefs_routing" translatable="false">RoutingOptions</string>
<string name="pref_autodownload" translatable="false">AutoDownloadMap</string>
<string name="pref_3d" translatable="false">3D</string>

View File

@@ -609,6 +609,7 @@
\nOpen your device\'s settings → Language and input → Speech → Text to speech output.
\nHere you can manage settings for speech synthesis (for example, download language pack for offline use) and select another text-to-speech engine.</string>
<string name="prefs_languages_information_off_link">For more information please check this guide</string>
<string name="prefs_speed_cameras_information">Speed camera warnings are disabled in countries where alerts are prohibited by local law.</string>
<string name="transliteration_title">Transliterate into Latin alphabet</string>
<string name="learn_more">Learn more</string>
<!-- User selected the destination by pressing Route To, but the current position is unknown. User needs to select a starting point of a route using search or by tapping on the map and then pressing "Route From". -->

View File

@@ -424,17 +424,4 @@
<item name="android:maxWidth">@dimen/map_buttons_bottom_max_width</item>
<item name="android:padding">@dimen/nav_frame_padding</item>
</style>
<style name="ShapeAppearance.MapButton.Zoom.Plus" parent="">
<item name="cornerSizeTopLeft">10%</item>
<item name="cornerSizeTopRight">10%</item>
<item name="cornerSizeBottomRight">50%</item>
<item name="cornerSizeBottomLeft">50%</item>
</style>
<style name="ShapeAppearance.MapButton.Zoom.Minus" parent="">
<item name="cornerSizeBottomLeft">10%</item>
<item name="cornerSizeBottomRight">10%</item>
<item name="cornerSizeTopLeft">50%</item>
<item name="cornerSizeTopRight">50%</item>
</style>
</resources>

View File

@@ -57,4 +57,11 @@
android:entryValues="@array/speed_cameras_values"
android:defaultValue="@string/auto_enum_value"
app:iconSpaceReserved="false" />
<Preference
android:enabled="true"
android:key="@string/pref_tts_info_link"
android:persistent="false"
android:selectable="false"
android:summary="@string/prefs_speed_cameras_information"
app:iconSpaceReserved="false" />
</androidx.preference.PreferenceScreen>

View File

@@ -26,7 +26,6 @@ import app.organicmaps.sdk.util.LocationUtils;
import app.organicmaps.sdk.util.NetworkPolicy;
import app.organicmaps.sdk.util.log.Logger;
import org.chromium.base.ObserverList;
import java.util.ArrayList;
public class LocationHelper implements BaseLocationProvider.Listener
{
@@ -36,8 +35,6 @@ public class LocationHelper implements BaseLocationProvider.Listener
private static final long AGPS_EXPIRATION_TIME_MS = 16 * 60 * 60 * 1000; // 16 hours
private static final long LOCATION_UPDATE_TIMEOUT_MS = 30 * 1000; // 30 seconds
private static final double SPEED_AVERAGING_TIME = 0.5; // 0.5 seconds
@NonNull
private final Context mContext;
@NonNull
@@ -59,10 +56,6 @@ public class LocationHelper implements BaseLocationProvider.Listener
private Handler mHandler;
private Runnable mLocationTimeoutRunnable = this::notifyLocationUpdateTimeout;
private double mTimeElapsedAtLastAverage = Double.NaN;
private float mLastAverageSpeed = Float.NaN;
private ArrayList<Float> mSpeedHistory = new ArrayList<>();
@NonNull
private final GnssStatusCompat.Callback mGnssStatusCallback = new GnssStatusCompat.Callback() {
@Override
@@ -174,8 +167,6 @@ public class LocationHelper implements BaseLocationProvider.Listener
mSavedLocation.getLongitude(), mSavedLocation.getAccuracy(),
mSavedLocation.getAltitude(), mSavedLocation.getSpeed(),
mSavedLocation.getBearing());
updateSpeedHistory();
}
private void notifyLocationUpdateTimeout()
@@ -488,41 +479,4 @@ public class LocationHelper implements BaseLocationProvider.Listener
Framework.nativeRunFirstLaunchAnimation();
}
}
private void updateSpeedHistory()
{
if (mSavedLocation == null)
{
return;
}
if (Double.isNaN(mTimeElapsedAtLastAverage))
{
mTimeElapsedAtLastAverage = mSavedLocation.getElapsedRealtimeNanos() * 1.0E-9;
}
mSpeedHistory.add(mSavedLocation.getSpeed());
}
public float getAverageSpeed()
{
if (mSavedLocation == null)
return Float.NaN;
if (Double.isNaN(mTimeElapsedAtLastAverage))
updateSpeedHistory();
double timeDiff = mSavedLocation.getElapsedRealtimeNanos() * 1.0E-9 - mTimeElapsedAtLastAverage;
if (timeDiff < SPEED_AVERAGING_TIME || mSpeedHistory.isEmpty())
{
if (!Float.isNaN(mLastAverageSpeed))
return mLastAverageSpeed;
else
return mSavedLocation.getSpeed();
}
else {
mLastAverageSpeed = mSpeedHistory.stream().reduce(0.0F, Float::sum);
mLastAverageSpeed /= mSpeedHistory.size();
mSpeedHistory.clear();
mTimeElapsedAtLastAverage = mSavedLocation.getElapsedRealtimeNanos() * 1.0E-9;
return mLastAverageSpeed;
}
}
}

View File

@@ -14,9 +14,9 @@ import android.text.TextUtils;
import android.util.Pair;
import androidx.annotation.NonNull;
import androidx.annotation.Nullable;
import androidx.core.content.ContextCompat;
import androidx.core.os.ConfigurationCompat;
import androidx.core.os.LocaleListCompat;
import androidx.core.content.ContextCompat;
import androidx.media.AudioAttributesCompat;
import androidx.media.AudioFocusRequestCompat;
import androidx.media.AudioManagerCompat;
@@ -137,7 +137,8 @@ public enum TtsPlayer
return findSupportedLanguage(Config.TTS.getLanguage(), langs);
}
private @Nullable LanguageData getSystemLanguage(List<LanguageData> langs) {
private @Nullable LanguageData getSystemLanguage(List<LanguageData> langs)
{
LanguageData res;
// Try default system locale
@@ -147,7 +148,8 @@ public enum TtsPlayer
return res;
// Try other installed system locales
for(int i=0; i < mInstalledSystemLocales.size(); i++) {
for (int i = 0; i < mInstalledSystemLocales.size(); i++)
{
Locale loc = mInstalledSystemLocales.get(i);
res = findSupportedLanguage(loc, langs);
if (res != null && res.downloaded)
@@ -156,19 +158,20 @@ public enum TtsPlayer
return null;
}
private @Nullable LanguageData getTTSLanguage(List<LanguageData> langs) {
private @Nullable LanguageData getTTSLanguage(List<LanguageData> langs)
{
LanguageData res;
// Try all TTS installed languages
Set<Locale> ttsLocales = mTts.getAvailableLanguages();
for(Locale loc : ttsLocales) {
for (Locale loc : ttsLocales)
{
res = findSupportedLanguage(loc, langs);
if (res != null && res.downloaded)
return res;
}
return null;
}
private static @Nullable LanguageData getDefaultLanguage(List<LanguageData> langs)
@@ -386,7 +389,8 @@ public enum TtsPlayer
Logger.d("TtsPlayer", "Selected locale " + res.internalCode + " will be used for TTS");
return res;
}
Logger.d("TtsPlayer", "Selected locale " + Config.TTS.getLanguage() + " is not available or not downloaded, trying system locales...");
Logger.d("TtsPlayer", "Selected locale " + Config.TTS.getLanguage()
+ " is not available or not downloaded, trying system locales...");
res = getSystemLanguage(outList);
if (res != null && res.downloaded)
@@ -394,7 +398,8 @@ public enum TtsPlayer
Logger.d("TtsPlayer", "System locale " + res.internalCode + " will be used for TTS");
return res;
}
Logger.d("TtsPlayer", "None of the system locales are available, or they are not downloaded, trying default locale...");
Logger.d("TtsPlayer",
"None of the system locales are available, or they are not downloaded, trying default locale...");
res = getDefaultLanguage(outList);
if (res != null && res.downloaded)
@@ -402,7 +407,8 @@ public enum TtsPlayer
Logger.d("TtsPlayer", "Default locale " + res.internalCode + " will be used for TTS");
return res;
}
Logger.d("TtsPlayer", "Default locale " + DEFAULT_LOCALE + " can not be used either, trying all installed TTS locales...");
Logger.d("TtsPlayer",
"Default locale " + DEFAULT_LOCALE + " can not be used either, trying all installed TTS locales...");
res = getTTSLanguage(outList);
if (res != null && res.downloaded)
@@ -411,7 +417,8 @@ public enum TtsPlayer
return res;
}
Logger.d("TtsPlayer", "None of the TTS engine locales are available, or they are not downloaded, disabling TTS :( ");
Logger.d("TtsPlayer",
"None of the TTS engine locales are available, or they are not downloaded, disabling TTS :( ");
Config.TTS.setEnabled(false);
return null;
}

File diff suppressed because it is too large Load Diff

View File

@@ -13,7 +13,6 @@ node[shop],
node[amenity=car_wash],
node[amenity=fuel],
node[amenity=studio],
node[amenity=toilets],
node[amenity=vehicle_inspection],
node[craft],
node[landuse=industrial][industrial=mine],
@@ -138,6 +137,7 @@ node[amenity=prison],
node[amenity=recycling][recycling_type=centre],
node[amenity=sailing_school],
node[amenity=school],
node[amenity=toilets],
node[amenity=townhall],
node[amenity=university][name],
node[barrier=border_control],

View File

@@ -502,12 +502,12 @@ int main(int argc, char * argv[])
if (ImGui::GetIO().WantCaptureMouse)
framework.MakeFrameActive();
if (touchActive)
#if defined(OMIM_OS_MAC)
x *= visualScale;
x *= visualScale;
y *= visualScale;
#endif
if (touchActive)
framework.TouchEvent(GetTouchEvent(framework, x, y, touchMods, df::TouchEvent::TOUCH_MOVE));
framework.TouchEvent(GetTouchEvent(framework, x, y, touchMods, df::TouchEvent::TOUCH_MOVE));
};
glfwSetCursorPosCallback(window, [](GLFWwindow *, double x, double y) { handlers.onMouseMove(x, y); });

View File

@@ -165,16 +165,18 @@ void TestAltitudesBuilding(std::vector<TPoint3DList> const & roads, bool hasAlti
AltitudeGetter & altitudeGetter)
{
classificator::Load();
std::string const testDirFullPath = base::JoinPath(GetPlatform().WritableDir(), kTestDir);
ScopedDirCleanup testScopedDir(testDirFullPath);
Platform & platform = GetPlatform();
std::string const testDirFullPath = base::JoinPath(platform.WritableDir(), kTestDir);
// Building mwm without altitude section.
LocalCountryFile country(testDirFullPath, CountryFile(kTestMwm), 1);
ScopedDir testScopedDir(kTestDir);
ScopedFile testScopedMwm(base::JoinPath(kTestDir, kTestMwm + DATA_FILE_EXTENSION), ScopedFile::Mode::Create);
BuildMwmWithoutAltitudes(roads, country);
// Adding altitude section to mwm.
auto const mwmPath = base::JoinPath(testDirFullPath, kTestMwm + DATA_FILE_EXTENSION);
auto const mwmPath = testScopedMwm.GetFullPath();
BuildRoadAltitudes(mwmPath, altitudeGetter);
// Reading from mwm and testing altitude information.

View File

@@ -64,15 +64,18 @@ std::unique_ptr<CityRoads> LoadCityRoads(LocalCountryFile const & country)
/// section and then read from it.
void TestCityRoadsBuilding(vector<uint32_t> && cityRoadFeatureIds)
{
string const testDir = base::JoinPath(GetPlatform().WritableDir(), kTestDir);
ScopedDirCleanup scopedDir(testDir);
string const writableDir = GetPlatform().WritableDir();
// Building empty mwm.
LocalCountryFile country(testDir, CountryFile(kTestMwm), 0 /* version */);
LocalCountryFile country(base::JoinPath(writableDir, kTestDir), CountryFile(kTestMwm), 0 /* version */);
ScopedDir const scopedDir(kTestDir);
string const mwmRelativePath = base::JoinPath(kTestDir, kTestMwm + DATA_FILE_EXTENSION);
ScopedFile const scopedMwm(mwmRelativePath, ScopedFile::Mode::Create);
BuildEmptyMwm(country);
// Adding city_roads section to mwm.
string const mwmFullPath = base::JoinPath(testDir, kTestMwm + DATA_FILE_EXTENSION);
string const mwmFullPath = base::JoinPath(writableDir, mwmRelativePath);
vector<uint32_t> originalCityRoadFeatureIds = cityRoadFeatureIds;
routing_builder::SerializeCityRoads(mwmFullPath, std::move(cityRoadFeatureIds));

View File

@@ -73,18 +73,19 @@ void TestMaxspeedsSection(Features const & roads, string const & maxspeedsCsvCon
FeatureIdToOsmId const & featureIdToOsmId)
{
classificator::Load();
string const testDirFullPath = base::JoinPath(GetPlatform().WritableDir(), kTestDir);
ScopedDirCleanup testScopedDir(testDirFullPath);
ScopedDir testScopedDir(kTestDir);
// Writing |maxspeedsCsvContent| to a file in |kTestDir|.
ScopedFile testScopedMaxspeedsCsv(base::JoinPath(kTestDir, kCsv), maxspeedsCsvContent);
// Writing |roads| to test mwm.
LocalCountryFile country(testDirFullPath, CountryFile(kTestMwm), 1 /* version */);
string const testMwm = kTestMwm + DATA_FILE_EXTENSION;
ScopedFile testScopedMwm(base::JoinPath(kTestDir, testMwm), ScopedFile::Mode::Create);
BuildGeometry(roads, country);
string const testMwmFullPath = base::JoinPath(testDirFullPath, kTestMwm + DATA_FILE_EXTENSION);
string const testMwmFullPath = base::JoinPath(testDirFullPath, testMwm);
// Create routing graph for test mwm.
auto const countryParentGetter = [](std::string const &) { return string(); };

View File

@@ -134,26 +134,33 @@ void LoadRestrictions(string const & mwmFilePath, vector<Restriction> & restrict
/// loads the restriction section and test loaded restrictions.
/// \param |restrictionPath| comma separated text with restrictions in osm id terms.
/// \param |osmIdsToFeatureIdContent| comma separated text with mapping from osm ids to feature ids.
void TestRestrictionBuilding(string const & restrictionContent, string const & osmIdsToFeatureIdContent,
void TestRestrictionBuilding(string const & restrictionPath, string const & osmIdsToFeatureIdContent,
unique_ptr<IndexGraph> graph, vector<Restriction> & expectedNotUTurn,
vector<RestrictionUTurnForTests> & expectedUTurn)
{
string const targetDir = base::JoinPath(GetPlatform().WritableDir(), kTestDir);
ScopedDirCleanup scopedDir(targetDir);
Platform & platform = GetPlatform();
string const writableDir = platform.WritableDir();
string const targetDir = base::JoinPath(writableDir, kTestDir);
// Building empty mwm.
LocalCountryFile country(targetDir, CountryFile(kTestMwm), 0 /* version */);
ScopedDir const scopedDir(kTestDir);
string const mwmRelativePath = base::JoinPath(kTestDir, kTestMwm + DATA_FILE_EXTENSION);
ScopedFile const scopedMwm(mwmRelativePath, ScopedFile::Mode::Create);
BuildEmptyMwm(country);
// Creating a file with restrictions.
ScopedFile const restrictionScopedFile(base::JoinPath(kTestDir, kRestrictionFileName), restrictionContent);
string const restrictionRelativePath = base::JoinPath(kTestDir, kRestrictionFileName);
ScopedFile const restrictionScopedFile(restrictionRelativePath, restrictionPath);
// Creating osm ids to feature ids mapping.
string const osmIdsToFeatureIdFullPath = base::JoinPath(targetDir, kOsmIdsToFeatureIdsName);
string const mappingRelativePath = base::JoinPath(kTestDir, kOsmIdsToFeatureIdsName);
ScopedFile const mappingFile(mappingRelativePath, ScopedFile::Mode::Create);
string const & osmIdsToFeatureIdFullPath = mappingFile.GetFullPath();
ReEncodeOsmIdsToFeatureIdsMapping(osmIdsToFeatureIdContent, osmIdsToFeatureIdFullPath);
string const restrictionFullPath = base::JoinPath(targetDir, kRestrictionFileName);
string const mwmFullPath = base::JoinPath(targetDir, kTestMwm + DATA_FILE_EXTENSION);
string const restrictionFullPath = base::JoinPath(writableDir, restrictionRelativePath);
string const & mwmFullPath = scopedMwm.GetFullPath();
// Prepare data to collector.
auto restrictionCollector =

View File

@@ -151,7 +151,7 @@ public:
// Set speed as-is from parent link.
if (parentHwType == hwType)
return {{s.GetForward(), s.GetUnits()}};
/*
using routing::HighwayType;
if ((*parentHwType == HighwayType::HighwayMotorway && hwType == HighwayType::HighwayMotorwayLink) ||
(*parentHwType == HighwayType::HighwayTrunk && hwType == HighwayType::HighwayTrunkLink) ||
@@ -163,6 +163,7 @@ public:
return converter.ClosestValidMacro(
{base::asserted_cast<MaxspeedType>(std::lround(s.GetForward() * kLinkToMainSpeedFactor)), s.GetUnits()});
}
*/
return {};
};

View File

@@ -2,6 +2,8 @@
#include "indexer/data_source.hpp"
#include "base/assert.hpp"
#include "defines.hpp"
namespace descriptions
@@ -18,28 +20,17 @@ std::string Loader::GetWikiDescription(FeatureID const & featureId, std::vector<
if (!value.m_cont.IsExist(DESCRIPTIONS_FILE_TAG))
return {};
// No need to have separate mutexes for each MWM since there is no concurrent Wiki pages reading.
// Pros: lock is called once and a simple logic with OnMwmDeregistered synchronization.
/// @todo Consider removing mutex at all or make wiki loading async (PlacePage info).
EntryPtr entry;
{
std::lock_guard<std::mutex> lock(m_mutex);
entry = m_deserializers.try_emplace(featureId.m_mwmId, std::make_shared<Entry>()).first->second;
}
std::lock_guard lock(m_mutex);
Deserializer & deserializer = m_deserializers[featureId.m_mwmId];
ASSERT(entry, ());
auto readerPtr = value.m_cont.GetReader(DESCRIPTIONS_FILE_TAG);
return deserializer.Deserialize(*readerPtr.GetPtr(), featureId.m_index, langPriority);
}
void Loader::OnMwmDeregistered(platform::LocalCountryFile const & countryFile)
{
std::lock_guard lock(m_mutex);
for (auto it = m_deserializers.begin(); it != m_deserializers.end(); ++it)
{
if (it->first.IsDeregistered(countryFile))
{
m_deserializers.erase(it);
break;
}
}
std::lock_guard<std::mutex> lock(entry->m_mutex);
return entry->m_deserializer.Deserialize(*readerPtr.GetPtr(), featureId.m_index, langPriority);
}
} // namespace descriptions

View File

@@ -5,7 +5,9 @@
#include "indexer/feature_decl.hpp"
#include "indexer/mwm_set.hpp"
#include <cstdint>
#include <map>
#include <memory>
#include <mutex>
#include <string>
#include <vector>
@@ -21,11 +23,18 @@ public:
explicit Loader(DataSource const & dataSource) : m_dataSource(dataSource) {}
std::string GetWikiDescription(FeatureID const & featureId, std::vector<int8_t> const & langPriority);
void OnMwmDeregistered(platform::LocalCountryFile const & countryFile);
private:
struct Entry
{
std::mutex m_mutex;
Deserializer m_deserializer;
};
using EntryPtr = std::shared_ptr<Entry>;
DataSource const & m_dataSource;
std::map<MwmSet::MwmId, Deserializer> m_deserializers;
std::map<MwmSet::MwmId, EntryPtr> m_deserializers;
std::mutex m_mutex;
};
} // namespace descriptions

View File

@@ -231,6 +231,14 @@ void SymbolsTexture::Invalidate(ref_ptr<dp::GraphicsContext> context, std::strin
Load(context, skinPathName, allocator);
}
void SymbolsTexture::Invalidate(ref_ptr<dp::GraphicsContext> context, std::string const & skinPathName,
ref_ptr<HWTextureAllocator> allocator,
std::vector<drape_ptr<HWTexture>> & internalTextures)
{
internalTextures.push_back(std::move(m_hwTexture));
Invalidate(context, skinPathName, allocator);
}
ref_ptr<Texture::ResourceInfo> SymbolsTexture::FindResource(Texture::Key const & key, bool & newResource)
{
newResource = false;

View File

@@ -36,6 +36,8 @@ public:
void Invalidate(ref_ptr<dp::GraphicsContext> context, std::string const & skinPathName,
ref_ptr<HWTextureAllocator> allocator);
void Invalidate(ref_ptr<dp::GraphicsContext> context, std::string const & skinPathName,
ref_ptr<HWTextureAllocator> allocator, std::vector<drape_ptr<HWTexture>> & internalTextures);
bool IsSymbolContained(std::string const & symbolName) const;

View File

@@ -73,12 +73,6 @@ public:
static bool IsPowerOfTwo(uint32_t width, uint32_t height);
void DeferredCleanup(std::vector<drape_ptr<HWTexture>> & toCleanup)
{
toCleanup.push_back(std::move(m_hwTexture));
Destroy();
}
protected:
void Destroy();
bool AllocateTexture(ref_ptr<dp::GraphicsContext> context, ref_ptr<HWTextureAllocator> allocator);

View File

@@ -87,10 +87,6 @@ drape_ptr<Texture> CreateArrowTexture(ref_ptr<dp::GraphicsContext> context,
useDefaultResourceFolder ? StaticTexture::kDefaultResource : std::string(),
dp::TextureFormat::RGBA8, textureAllocator, true /* allowOptional */);
}
// There is no "arrow-texture.png".
// BackendRenderer::m_arrow3dPreloadedData mesh is used by default.
/// @todo Texture arrow is still present in case if somebody wants to use it?
return make_unique_dp<StaticTexture>(context, "arrow-texture.png", StaticTexture::kDefaultResource,
dp::TextureFormat::RGBA8, textureAllocator, true /* allowOptional */);
}
@@ -319,7 +315,39 @@ void TextureManager::Init(ref_ptr<dp::GraphicsContext> context, Params const & p
m_smaaSearchTexture = make_unique_dp<StaticTexture>(context, "smaa-search.png", StaticTexture::kDefaultResource,
dp::TextureFormat::Red, make_ref(m_textureAllocator));
InitStipplePen(params);
// Initialize patterns (reserved ./data/patterns.txt lines count).
std::set<PenPatternT> patterns;
double const visualScale = params.m_visualScale;
uint32_t rowsCount = 0;
impl::ParsePatternsList(params.m_patterns, [&](buffer_vector<double, 8> const & pattern)
{
PenPatternT toAdd;
for (double d : pattern)
toAdd.push_back(PatternFloat2Pixel(d * visualScale));
if (!patterns.insert(toAdd).second)
return;
if (IsTrianglePattern(toAdd))
{
rowsCount = rowsCount + toAdd[2] + toAdd[3];
}
else
{
ASSERT_EQUAL(toAdd.size(), 2, ());
++rowsCount;
}
});
m_stipplePenTexture = make_unique_dp<StipplePenTexture>(StipplePenTextureSize(rowsCount, m_maxTextureSize),
make_ref(m_textureAllocator));
LOG(LDEBUG, ("Patterns texture size =", m_stipplePenTexture->GetWidth(), m_stipplePenTexture->GetHeight()));
ref_ptr<StipplePenTexture> stipplePenTex = make_ref(m_stipplePenTexture);
for (auto const & p : patterns)
stipplePenTex->ReservePattern(p);
// Initialize colors (reserved ./data/colors.txt lines count).
std::vector<dp::Color> colors;
@@ -352,73 +380,25 @@ void TextureManager::Init(ref_ptr<dp::GraphicsContext> context, Params const & p
m_nothingToUpload.clear();
}
void TextureManager::InitStipplePen(Params const & params)
{
// Initialize patterns (reserved ./data/patterns.txt lines count).
std::set<PenPatternT> patterns;
uint32_t rowsCount = 0;
impl::ParsePatternsList(params.m_patterns, [&](buffer_vector<double, 8> const & pattern)
{
PenPatternT toAdd;
for (double d : pattern)
toAdd.push_back(PatternFloat2Pixel(d * params.m_visualScale));
if (!patterns.insert(toAdd).second)
return;
if (IsTrianglePattern(toAdd))
{
rowsCount = rowsCount + toAdd[2] + toAdd[3];
}
else
{
ASSERT_EQUAL(toAdd.size(), 2, ());
++rowsCount;
}
});
m_stipplePenTexture = make_unique_dp<StipplePenTexture>(StipplePenTextureSize(rowsCount, m_maxTextureSize),
make_ref(m_textureAllocator));
LOG(LDEBUG, ("Patterns texture size =", m_stipplePenTexture->GetWidth(), m_stipplePenTexture->GetHeight()));
ref_ptr<StipplePenTexture> stipplePenTex = make_ref(m_stipplePenTexture);
for (auto const & p : patterns)
stipplePenTex->ReservePattern(p);
}
void TextureManager::OnSwitchMapStyle(ref_ptr<dp::GraphicsContext> context)
{
CHECK(m_isInitialized, ());
bool const isVulkan = context->GetApiVersion() == dp::ApiVersion::Vulkan;
// Here we need invalidate only textures which can be changed in map style switch.
// Now we update only symbol textures, if we need update other textures they must be added here.
// For Vulkan we use m_texturesToCleanup to defer textures destroying.
for (auto const & texture : m_symbolTextures)
for (auto const & m_symbolTexture : m_symbolTextures)
{
ref_ptr<SymbolsTexture> symbolsTexture = make_ref(texture);
if (isVulkan)
symbolsTexture->DeferredCleanup(m_texturesToCleanup);
ref_ptr<SymbolsTexture> symbolsTexture = make_ref(m_symbolTexture);
ASSERT(symbolsTexture != nullptr, ());
symbolsTexture->Invalidate(context, m_resPostfix, make_ref(m_textureAllocator));
if (context->GetApiVersion() != dp::ApiVersion::Vulkan)
symbolsTexture->Invalidate(context, m_resPostfix, make_ref(m_textureAllocator));
else
symbolsTexture->Invalidate(context, m_resPostfix, make_ref(m_textureAllocator), m_texturesToCleanup);
}
}
void TextureManager::OnVisualScaleChanged(ref_ptr<dp::GraphicsContext> context, Params const & params)
{
m_resPostfix = params.m_resPostfix;
OnSwitchMapStyle(context);
if (context->GetApiVersion() == dp::ApiVersion::Vulkan)
m_stipplePenTexture->DeferredCleanup(m_texturesToCleanup);
InitStipplePen(params);
}
void TextureManager::InvalidateArrowTexture(ref_ptr<dp::GraphicsContext> context,
std::string const & texturePath /* = {} */,
bool useDefaultResourceFolder /* = false */)
@@ -436,13 +416,10 @@ void TextureManager::ApplyInvalidatedStaticTextures()
}
}
std::vector<drape_ptr<HWTexture>> TextureManager::GetTexturesToCleanup()
void TextureManager::GetTexturesToCleanup(std::vector<drape_ptr<HWTexture>> & textures)
{
CHECK(m_isInitialized, ());
auto res = std::move(m_texturesToCleanup);
m_texturesToCleanup.clear();
return res;
std::swap(textures, m_texturesToCleanup);
}
bool TextureManager::GetSymbolRegionSafe(std::string const & symbolName, SymbolRegion & region)

View File

@@ -77,9 +77,7 @@ public:
void Init(ref_ptr<dp::GraphicsContext> context, Params const & params);
void OnSwitchMapStyle(ref_ptr<dp::GraphicsContext> context);
void OnVisualScaleChanged(ref_ptr<dp::GraphicsContext> context, Params const & params);
std::vector<drape_ptr<HWTexture>> GetTexturesToCleanup();
void GetTexturesToCleanup(std::vector<drape_ptr<HWTexture>> & textures);
bool GetSymbolRegionSafe(std::string const & symbolName, SymbolRegion & region);
void GetSymbolRegion(std::string const & symbolName, SymbolRegion & region);
@@ -123,8 +121,6 @@ public:
ref_ptr<HWTextureAllocator> GetTextureAllocator() const;
private:
void InitStipplePen(Params const & params);
struct GlyphGroup
{
std::set<GlyphFontAndId> m_glyphKeys;

View File

@@ -525,11 +525,9 @@ void ApplyPointFeature::ProcessPointRules(SymbolRuleProto const * symbolRule, Ca
params.m_depth = PriorityToDepth(symbolRule->priority(), drule::symbol, 0);
params.m_symbolName = symbolRule->name();
ASSERT_GREATER_OR_EQUAL(symbolRule->min_distance(), 0, ());
// Where 0.1 comes from: https://github.com/organicmaps/organicmaps/pull/649
auto const & vp = df::VisualParams::Instance();
params.m_extendingSize = static_cast<uint32_t>(vp.GetVisualScale() * symbolRule->min_distance() * 0.1);
params.m_extendingSize =
static_cast<uint32_t>(vp.GetVisualScale() * symbolRule->min_distance() * vp.GetPoiExtendScale());
params.m_posZ = m_posZ;
params.m_hasArea = HasArea();
params.m_prioritized = createdByEditor;

View File

@@ -17,6 +17,8 @@
#include "drape/support_manager.hpp"
#include "drape/texture_manager.hpp"
#include "indexer/scales.hpp"
#include "platform/platform.hpp"
#include "base/file_name_utils.hpp"
@@ -353,37 +355,18 @@ void BackendRenderer::AcceptMessage(ref_ptr<Message> message)
m_trafficGenerator->InvalidateTexturesCache();
m_transitBuilder->RebuildSchemes(m_context, m_texMng);
CleanupTextures();
break;
}
// For Vulkan we initialize deferred cleaning up.
if (m_context->GetApiVersion() == dp::ApiVersion::Vulkan)
{
std::vector<drape_ptr<dp::HWTexture>> textures;
m_texMng->GetTexturesToCleanup(textures);
if (!textures.empty())
{
m_commutator->PostMessage(ThreadsCommutator::RenderThread,
make_unique_dp<CleanupTexturesMessage>(std::move(textures)), MessagePriority::Normal);
}
}
case Message::Type::VisualScaleChanged:
{
ref_ptr<VisualScaleChangedMessage> msg = message;
msg->FilterDependentMessages();
CHECK(m_context != nullptr, ());
dp::TextureManager::Params params;
params.m_resPostfix = VisualParams::Instance().GetResourcePostfix();
params.m_visualScale = df::VisualParams::Instance().GetVisualScale();
#ifdef BUILD_DESIGNER
params.m_patterns = "patterns_design.txt";
#else
params.m_patterns = "patterns.txt";
#endif // BUILD_DESIGNER
m_texMng->OnVisualScaleChanged(m_context, params);
RecacheMapShapes();
RecacheGui(m_lastWidgetsInfo, false /* needResetOldGui */);
#ifdef RENDER_DEBUG_INFO_LABELS
RecacheDebugLabels();
#endif
m_trafficGenerator->InvalidateTexturesCache();
m_transitBuilder->RebuildSchemes(m_context, m_texMng);
CleanupTextures();
break;
}
@@ -628,8 +611,21 @@ void BackendRenderer::AcceptMessage(ref_ptr<Message> message)
m_arrow3dPreloadedData = Arrow3d::PreloadMesh(m_arrow3dCustomDecl, m_texMng);
}
// Recache map shapes.
RecacheMapShapes();
CleanupTextures();
// For Vulkan we initialize deferred cleaning up.
if (m_context->GetApiVersion() == dp::ApiVersion::Vulkan)
{
std::vector<drape_ptr<dp::HWTexture>> textures;
m_texMng->GetTexturesToCleanup(textures);
if (!textures.empty())
{
m_commutator->PostMessage(ThreadsCommutator::RenderThread,
make_unique_dp<CleanupTexturesMessage>(std::move(textures)), MessagePriority::Normal);
}
}
break;
}
@@ -776,18 +772,6 @@ void BackendRenderer::RecacheMapShapes()
m_commutator->PostMessage(ThreadsCommutator::RenderThread, std::move(msg), MessagePriority::Normal);
}
void BackendRenderer::CleanupTextures()
{
// For Vulkan we initialize deferred cleaning up.
if (m_context->GetApiVersion() == dp::ApiVersion::Vulkan)
{
auto textures = m_texMng->GetTexturesToCleanup();
if (!textures.empty())
m_commutator->PostMessage(ThreadsCommutator::RenderThread,
make_unique_dp<CleanupTexturesMessage>(std::move(textures)), MessagePriority::Normal);
}
}
void BackendRenderer::FlushGeometry(TileKey const & key, dp::RenderState const & state,
drape_ptr<dp::RenderBucket> && buffer)
{

View File

@@ -83,7 +83,6 @@ private:
void RecacheGui(gui::TWidgetsInitInfo const & initInfo, bool needResetOldGui);
void RecacheChoosePositionMark();
void RecacheMapShapes();
void CleanupTextures();
#ifdef RENDER_DEBUG_INFO_LABELS
void RecacheDebugLabels();

View File

@@ -897,8 +897,10 @@ void DrapeEngine::UpdateVisualScale(double vs, bool needStopRendering)
if (needStopRendering)
SetRenderingEnabled();
m_threadCommutator->PostMessage(ThreadsCommutator::RenderThread, make_unique_dp<UpdateVisualScaleMessage>(),
MessagePriority::High);
RecacheGui(false);
RecacheMapShapes();
m_threadCommutator->PostMessage(ThreadsCommutator::RenderThread,
make_unique_dp<RecoverContextDependentResourcesMessage>(), MessagePriority::Normal);
}
void DrapeEngine::UpdateMyPositionRoutingOffset(bool useDefault, int offsetY)

View File

@@ -640,11 +640,51 @@ void FrontendRenderer::AcceptMessage(ref_ptr<Message> message)
break;
}
case Message::Type::RecoverContextDependentResources: UpdateContextDependentResources(); break;
case Message::Type::RecoverContextDependentResources:
{
UpdateContextDependentResources();
break;
}
case Message::Type::UpdateMapStyle: UpdateAll<SwitchMapStyleMessage>(); break;
case Message::Type::UpdateMapStyle:
{
#ifdef BUILD_DESIGNER
classificator::Load();
#endif // BUILD_DESIGNER
case Message::Type::VisualScaleChanged: UpdateAll<VisualScaleChangedMessage>(); break;
// Clear all graphics.
for (RenderLayer & layer : m_layers)
{
layer.m_renderGroups.clear();
layer.m_isDirty = false;
}
// Must be recreated on map style changing.
CHECK(m_context != nullptr, ());
m_transitBackground = make_unique_dp<ScreenQuadRenderer>(m_context);
// Invalidate read manager.
{
BaseBlockingMessage::Blocker blocker;
m_commutator->PostMessage(ThreadsCommutator::ResourceUploadThread,
make_unique_dp<InvalidateReadManagerRectMessage>(blocker), MessagePriority::Normal);
blocker.Wait();
}
// Delete all messages which can contain render states (and textures references inside).
auto f = [this]() { InstantMessageFilter([](ref_ptr<Message> msg) { return msg->ContainsRenderState(); }); };
// Notify backend renderer and wait for completion.
{
BaseBlockingMessage::Blocker blocker;
m_commutator->PostMessage(ThreadsCommutator::ResourceUploadThread,
make_unique_dp<SwitchMapStyleMessage>(blocker, std::move(f)), MessagePriority::Normal);
blocker.Wait();
}
UpdateContextDependentResources();
break;
}
case Message::Type::AllowAutoZoom:
{
@@ -770,7 +810,7 @@ void FrontendRenderer::AcceptMessage(ref_ptr<Message> message)
zoom = scales::GetAddNewPlaceScale();
AddUserEvent(make_unique_dp<SetCenterEvent>(
pt ? *pt : m_userEventStream.GetCurrentScreen().GlobalRect().Center(), zoom, true /* isAnim */,
true /* trackVisibleViewport */, nullptr /* parallelAnimCreator */));
false /* trackVisibleViewport */, nullptr /* parallelAnimCreator */));
}
else
{
@@ -983,46 +1023,6 @@ void FrontendRenderer::AcceptMessage(ref_ptr<Message> message)
}
}
template <class MessageT>
void FrontendRenderer::UpdateAll()
{
#ifdef BUILD_DESIGNER
classificator::Load();
#endif // BUILD_DESIGNER
// Clear all graphics.
for (RenderLayer & layer : m_layers)
{
layer.m_renderGroups.clear();
layer.m_isDirty = false;
}
// Must be recreated on map style changing.
CHECK(m_context != nullptr, ());
m_transitBackground = make_unique_dp<ScreenQuadRenderer>(m_context);
// Invalidate read manager.
{
BaseBlockingMessage::Blocker blocker;
m_commutator->PostMessage(ThreadsCommutator::ResourceUploadThread,
make_unique_dp<InvalidateReadManagerRectMessage>(blocker), MessagePriority::Normal);
blocker.Wait();
}
// Delete all messages which can contain render states (and textures references inside).
auto f = [this]() { InstantMessageFilter([](ref_ptr<Message> msg) { return msg->ContainsRenderState(); }); };
// Notify backend renderer and wait for completion.
{
BaseBlockingMessage::Blocker blocker;
m_commutator->PostMessage(ThreadsCommutator::ResourceUploadThread, make_unique_dp<MessageT>(blocker, std::move(f)),
MessagePriority::Normal);
blocker.Wait();
}
UpdateContextDependentResources();
}
std::unique_ptr<threads::IRoutine> FrontendRenderer::CreateRoutine()
{
return std::make_unique<Routine>(*this);

View File

@@ -247,9 +247,6 @@ private:
void ReleaseResources();
void UpdateContextDependentResources();
template <class MessageT>
void UpdateAll();
void BeginUpdateOverlayTree(ScreenBase const & modelView);
void UpdateOverlayTree(ScreenBase const & modelView, drape_ptr<RenderGroup> & renderGroup);
void EndUpdateOverlayTree();

View File

@@ -103,7 +103,6 @@ std::string DebugPrint(Message::Type msgType)
case Message::Type::EnableIsolines: return "EnableIsolines";
case Message::Type::OnEnterBackground: return "OnEnterBackground";
case Message::Type::Arrow3dRecache: return "Arrow3dRecache";
case Message::Type::VisualScaleChanged: return "VisualScaleChanged";
}
ASSERT(false, ("Unknown message type."));
return "Unknown type";

View File

@@ -103,8 +103,7 @@ public:
NotifyGraphicsReady,
EnableIsolines,
OnEnterBackground,
Arrow3dRecache,
VisualScaleChanged,
Arrow3dRecache
};
virtual ~Message() = default;

View File

@@ -1,6 +1,7 @@
#pragma once
#include "drape_frontend/circles_pack_shape.hpp"
#include "drape_frontend/color_constants.hpp"
#include "drape_frontend/custom_features_context.hpp"
#include "drape_frontend/drape_api.hpp"
#include "drape_frontend/drape_api_builder.hpp"
@@ -13,7 +14,8 @@
#include "drape_frontend/overlay_batcher.hpp"
#include "drape_frontend/postprocess_renderer.hpp"
#include "drape_frontend/render_node.hpp"
#include "drape_frontend/route_shape.hpp"
#include "drape_frontend/render_state_extension.hpp"
#include "drape_frontend/route_builder.hpp"
#include "drape_frontend/selection_shape.hpp"
#include "drape_frontend/tile_utils.hpp"
#include "drape_frontend/traffic_generator.hpp"
@@ -24,10 +26,13 @@
#include "drape/pointers.hpp"
#include "drape/render_bucket.hpp"
#include "drape/viewport.hpp"
#include "platform/location.hpp"
#include "geometry/polyline2d.hpp"
#include "geometry/rect2d.hpp"
#include "geometry/screenbase.hpp"
#include "geometry/triangle2d.hpp"
#include <condition_variable>
@@ -35,6 +40,7 @@
#include <map>
#include <mutex>
#include <optional>
#include <utility>
#include <vector>
namespace df
@@ -731,12 +737,6 @@ public:
Type GetType() const override { return Type::UpdateMapStyle; }
};
class UpdateVisualScaleMessage : public Message
{
public:
Type GetType() const override { return Type::VisualScaleChanged; }
};
class FollowRouteMessage : public Message
{
public:
@@ -783,14 +783,6 @@ private:
FilterMessagesHandler m_filterMessagesHandler;
};
class VisualScaleChangedMessage : public SwitchMapStyleMessage
{
public:
using SwitchMapStyleMessage::SwitchMapStyleMessage;
Type GetType() const override { return Type::VisualScaleChanged; }
};
class InvalidateMessage : public Message
{
public:

View File

@@ -4,8 +4,14 @@
#include "indexer/scales.hpp"
#include "platform/settings.hpp"
#include "geometry/angles.hpp"
#include "geometry/distance_on_sphere.hpp"
#include "geometry/point2d.hpp"
#include "geometry/transformations.hpp"
#include "base/logging.hpp"
namespace df
{

View File

@@ -2,6 +2,8 @@
#include "geometry/screenbase.hpp"
#include "base/matrix.hpp"
namespace df
{
extern double const kDefault3dScale;

View File

@@ -1,5 +1,9 @@
#include "screen_operations.hpp"
#include "drape_frontend/animation/interpolators.hpp"
#include "drape_frontend/animation/linear_animation.hpp"
#include "drape_frontend/animation/scale_animation.hpp"
#include "drape_frontend/animation_constants.hpp"
#include "drape_frontend/visual_params.hpp"
#include "indexer/scales.hpp"

View File

@@ -1,9 +1,5 @@
#include "drape_frontend/visual_params.hpp"
#include "indexer/scales.hpp"
#include "coding/point_coding.hpp" // kMwmPointAccuracy
#include "geometry/mercator.hpp"
#include "base/assert.hpp"
@@ -16,11 +12,21 @@
#include <algorithm>
#include <cmath>
#include <limits>
#include <utility>
namespace df
{
using VisualScale = std::pair<std::string, double>;
#ifdef DEBUG
static bool g_isInited = false;
#define RISE_INITED g_isInited = true
#define ASSERT_INITED ASSERT(g_isInited, ())
#else
#define RISE_INITED
#define ASSERT_INITED
#endif
VisualParams & VisualParams::Instance()
{
static VisualParams vizParams;
@@ -29,8 +35,7 @@ VisualParams & VisualParams::Instance()
void VisualParams::Init(double vs, uint32_t tileSize)
{
CHECK(vs >= 1.0 && vs <= kMaxVisualScale, (vs));
CHECK(tileSize >= 32, (tileSize));
ASSERT_LESS_OR_EQUAL(vs, kMaxVisualScale, ());
VisualParams & vizParams = Instance();
vizParams.m_tileSize = tileSize;
@@ -42,34 +47,35 @@ void VisualParams::Init(double vs, uint32_t tileSize)
else
vizParams.m_glyphVisualParams = {0.5f, 0.06f, 0.2f, 0.01f, 0.49f, 0.04f};
vizParams.m_isInited = true;
RISE_INITED;
LOG(LINFO, ("Visual scale =", vs, "; Tile size =", tileSize, "; Resources =", GetResourcePostfix(vs)));
}
double VisualParams::GetFontScale() const
{
ASSERT(m_isInited, ());
ASSERT_INITED;
return m_fontScale;
}
void VisualParams::SetFontScale(double fontScale)
{
ASSERT(m_isInited, ());
ASSERT_INITED;
m_fontScale = math::Clamp(fontScale, 0.5, 2.0);
}
void VisualParams::SetVisualScale(double vs)
void VisualParams::SetVisualScale(double visualScale)
{
ASSERT(m_isInited, ());
CHECK(vs >= 1.0 && vs <= kMaxVisualScale, (vs));
m_visualScale = vs;
ASSERT_INITED;
ASSERT_LESS_OR_EQUAL(visualScale, kMaxVisualScale, ());
m_visualScale = visualScale;
LOG(LINFO, ("Visual scale =", vs));
LOG(LINFO, ("Visual scale =", visualScale));
}
std::string const & VisualParams::GetResourcePostfix(double visualScale)
{
ASSERT_INITED;
static VisualScale postfixes[] = {
/// @todo Not used in mobile because of minimal visual scale (@see visual_scale.hpp)
{"mdpi", kMdpiScale},
@@ -97,61 +103,52 @@ std::string const & VisualParams::GetResourcePostfix(double visualScale)
std::string const & VisualParams::GetResourcePostfix() const
{
ASSERT(m_isInited, ());
ASSERT_INITED;
return VisualParams::GetResourcePostfix(m_visualScale);
}
double VisualParams::GetVisualScale() const
{
ASSERT(m_isInited, ());
ASSERT_INITED;
return m_visualScale;
}
double VisualParams::GetPoiExtendScale() const
{
ASSERT_INITED;
return m_poiExtendScale;
}
uint32_t VisualParams::GetTileSize() const
{
CHECK(m_isInited, ());
ASSERT_INITED;
return m_tileSize;
}
uint32_t VisualParams::GetTouchRectRadius() const
{
<<<<<<< HEAD
ASSERT_INITED;
float constexpr kRadiusInPixels = 20.0f;
=======
ASSERT(m_isInited, ());
float const kRadiusInPixels = 20.0f;
>>>>>>> 9cff373c8 ([drape] Refactor VisualParams.)
return static_cast<uint32_t>(kRadiusInPixels * GetVisualScale());
}
double VisualParams::GetDragThreshold() const
{
<<<<<<< HEAD
ASSERT_INITED;
double constexpr kDragThresholdInPixels = 10.0;
=======
ASSERT(m_isInited, ());
double const kDragThresholdInPixels = 10.0;
>>>>>>> 9cff373c8 ([drape] Refactor VisualParams.)
return kDragThresholdInPixels * GetVisualScale();
}
double VisualParams::GetScaleThreshold() const
{
<<<<<<< HEAD
ASSERT_INITED;
double constexpr kScaleThresholdInPixels = 2.0;
=======
ASSERT(m_isInited, ());
double const kScaleThresholdInPixels = 2.0;
>>>>>>> 9cff373c8 ([drape] Refactor VisualParams.)
return kScaleThresholdInPixels * GetVisualScale();
}
VisualParams::GlyphVisualParams const & VisualParams::GetGlyphVisualParams() const
{
ASSERT(m_isInited, ());
ASSERT_INITED;
return m_glyphVisualParams;
}
@@ -181,7 +178,8 @@ int GetTileScaleBase(ScreenBase const & s)
int GetTileScaleBase(m2::RectD const & r)
{
double const sz = std::max(std::max(r.SizeX(), r.SizeY()), kMwmPointAccuracy);
double const sz = std::max(r.SizeX(), r.SizeY());
ASSERT_GREATER(sz, 0., ("Rect should not be a point:", r));
return std::max(1, math::iround(std::log2(mercator::Bounds::kRangeX / sz)));
}
@@ -192,7 +190,7 @@ double GetTileScaleBase(double drawScale)
int GetTileScaleIncrement(uint32_t tileSize, double visualScale)
{
return math::iround(std::log2(tileSize / 256.0 / visualScale));
return static_cast<int>(std::log2(tileSize / 256.0 / visualScale));
}
int GetTileScaleIncrement()
@@ -259,18 +257,10 @@ uint32_t CalculateTileSize(uint32_t screenWidth, uint32_t screenHeight)
#endif
}
namespace
{
double GetDrawTileScale(double baseScale)
{
return baseScale + GetTileScaleIncrement();
}
int GetDrawTileScale(int baseScale, uint32_t tileSize, double visualScale)
{
return baseScale + GetTileScaleIncrement(tileSize, visualScale);
return std::max(1, baseScale + GetTileScaleIncrement(tileSize, visualScale));
}
} // namespace
int GetDrawTileScale(ScreenBase const & s, uint32_t tileSize, double visualScale)
{
@@ -282,6 +272,17 @@ int GetDrawTileScale(m2::RectD const & r, uint32_t tileSize, double visualScale)
return GetDrawTileScale(GetTileScaleBase(r), tileSize, visualScale);
}
int GetDrawTileScale(int baseScale)
{
VisualParams const & p = VisualParams::Instance();
return GetDrawTileScale(baseScale, p.GetTileSize(), p.GetVisualScale());
}
double GetDrawTileScale(double baseScale)
{
return std::max(1.0, baseScale + GetTileScaleIncrement());
}
int GetDrawTileScale(ScreenBase const & s)
{
VisualParams const & p = VisualParams::Instance();

View File

@@ -1,10 +1,15 @@
#pragma once
#include "indexer/scales.hpp"
#include "geometry/rect2d.hpp"
#include "geometry/screenbase.hpp"
#include "base/macros.hpp"
#include <atomic>
#include <cstdint>
#include <string>
#include <vector>
namespace df
{
@@ -31,6 +36,8 @@ public:
std::string const & GetResourcePostfix() const;
double GetVisualScale() const;
/// This is a scale factor to decrease extending of bbox for POI icons. It could be removed with new style
double GetPoiExtendScale() const;
uint32_t GetTileSize() const;
/// How many pixels around touch point are used to get bookmark or POI in consideration of visual scale.
@@ -55,7 +62,7 @@ public:
void SetFontScale(double fontScale);
// This method can be called ONLY if rendering is disabled.
void SetVisualScale(double vs);
void SetVisualScale(double visualScale);
private:
VisualParams() = default;
@@ -64,8 +71,8 @@ private:
uint32_t m_tileSize = 0;
double m_visualScale = 0.0;
double m_fontScale = 1.0;
bool m_isInited = false;
double m_poiExtendScale = 0.1; // Found empirically.
std::atomic<double> m_fontScale = 1.0;
DISALLOW_COPY_AND_MOVE(VisualParams);
};
@@ -82,8 +89,11 @@ double GetTileScaleBase(double drawScale);
int GetTileScaleIncrement(uint32_t tileSize, double visualScale);
int GetTileScaleIncrement();
int GetDrawTileScale(int baseScale, uint32_t tileSize, double visualScale);
int GetDrawTileScale(ScreenBase const & s, uint32_t tileSize, double visualScale);
int GetDrawTileScale(m2::RectD const & r, uint32_t tileSize, double visualScale);
int GetDrawTileScale(int baseScale);
double GetDrawTileScale(double baseScale);
int GetDrawTileScale(ScreenBase const & s);
int GetDrawTileScale(m2::RectD const & r);

View File

@@ -5,6 +5,8 @@ set(SRC
altitude_loader.hpp
brands_holder.cpp
brands_holder.hpp
caching_rank_table_loader.cpp
caching_rank_table_loader.hpp
categories_holder.cpp
categories_holder.hpp
categories_holder_loader.cpp
@@ -153,6 +155,7 @@ file(COPY ${OTHER_FILES} DESTINATION ${CMAKE_BINARY_DIR})
omim_add_library(${PROJECT_NAME} ${SRC})
target_link_libraries(${PROJECT_NAME}
search # search::DummyRankTable in CachingRankTableLoader
platform
geometry
protobuf

View File

@@ -0,0 +1,45 @@
#include "indexer/caching_rank_table_loader.hpp"
#include "search/dummy_rank_table.hpp"
#include "indexer/data_source.hpp"
CachingRankTableLoader::CachingRankTableLoader(DataSource const & dataSource, std::string const & sectionName)
: m_dataSource(dataSource)
, m_sectionName(sectionName)
{}
uint8_t CachingRankTableLoader::Get(FeatureID const & featureId) const
{
auto const handle = m_dataSource.GetMwmHandleById(featureId.m_mwmId);
if (!handle.IsAlive())
return search::RankTable::kNoRank;
auto it = m_deserializers.find(featureId.m_mwmId);
if (it == m_deserializers.end())
{
auto rankTable = search::RankTable::Load(handle.GetValue()->m_cont, m_sectionName);
if (!rankTable)
rankTable = std::make_unique<search::DummyRankTable>();
auto const result = m_deserializers.emplace(featureId.m_mwmId, std::move(rankTable));
it = result.first;
}
return it->second->Get(featureId.m_index);
}
void CachingRankTableLoader::OnMwmDeregistered(platform::LocalCountryFile const & localFile)
{
for (auto it = m_deserializers.begin(); it != m_deserializers.end(); ++it)
{
if (it->first.IsDeregistered(localFile))
{
m_deserializers.erase(it);
return;
}
}
}

View File

@@ -0,0 +1,32 @@
#pragma once
#include "indexer/feature_decl.hpp"
#include "indexer/mwm_set.hpp"
#include "indexer/rank_table.hpp"
#include "base/macros.hpp"
#include <map>
#include <memory>
#include <string>
class DataSource;
struct FeatureID;
// *NOTE* This class IS NOT thread-safe.
class CachingRankTableLoader
{
public:
CachingRankTableLoader(DataSource const & dataSource, std::string const & sectionName);
/// @return 0 if there is no rank for feature.
uint8_t Get(FeatureID const & featureId) const;
void OnMwmDeregistered(platform::LocalCountryFile const & localFile);
private:
DataSource const & m_dataSource;
std::string const m_sectionName;
mutable std::map<MwmSet::MwmId, std::unique_ptr<search::RankTable>> m_deserializers;
DISALLOW_COPY(CachingRankTableLoader);
};

View File

@@ -276,6 +276,7 @@ Framework::Framework(FrameworkParams const & params, bool loadMaps)
, m_trafficManager(bind(&Framework::GetMwmsByRect, this, _1, false /* rough */), kMaxTrafficCacheSizeBytes,
m_routingManager.RoutingSession())
, m_lastReportedCountry(kInvalidCountryId)
, m_popularityLoader(m_featuresFetcher.GetDataSource(), POPULARITY_RANKS_FILE_TAG)
, m_descriptionsLoader(std::make_unique<descriptions::Loader>(m_featuresFetcher.GetDataSource()))
{
// Editor should be initialized from the main thread to set its ThreadChecker.
@@ -444,7 +445,7 @@ void Framework::OnMapDeregistered(platform::LocalCountryFile const & localFile)
m_transitManager.OnMwmDeregistered(localFile);
m_isolinesManager.OnMwmDeregistered(localFile);
m_trafficManager.OnMwmDeregistered(localFile);
m_descriptionsLoader->OnMwmDeregistered(localFile);
m_popularityLoader.OnMwmDeregistered(localFile);
m_storage.DeleteCustomCountryVersion(localFile);
};
@@ -3071,6 +3072,10 @@ osm::Editor::SaveResult Framework::SaveEditedMapObject(osm::EditableMapObject em
auto const result = osm::Editor::Instance().SaveEditedFeature(emo);
// Automatically select newly created and edited objects.
if (m_currentPlacePageInfo)
DeactivateMapSelection();
place_page::BuildInfo info;
info.m_mercator = emo.GetMercator();
info.m_featureId = emo.GetID();

View File

@@ -32,6 +32,7 @@
#include "editor/new_feature_categories.hpp"
#include "editor/osm_editor.hpp"
#include "indexer/caching_rank_table_loader.hpp"
#include "indexer/data_source.hpp"
#include "indexer/data_source_helpers.hpp"
#include "indexer/map_object.hpp"
@@ -483,6 +484,8 @@ private:
TrackRecordingUpdateHandler m_trackRecordingUpdateHandler;
CachingRankTableLoader m_popularityLoader;
std::unique_ptr<descriptions::Loader> m_descriptionsLoader;
public:

View File

@@ -57,16 +57,5 @@ std::string DebugPrint(ScopedDir const & dir)
os << "ScopedDir [" << dir.GetFullPath() << "]";
return os.str();
}
ScopedDirCleanup::ScopedDirCleanup(std::string const & path) : m_fullPath(path)
{
UNUSED_VALUE(Platform::MkDir(m_fullPath));
}
ScopedDirCleanup::~ScopedDirCleanup()
{
UNUSED_VALUE(Platform::RmDirRecursively(m_fullPath));
}
} // namespace tests_support
} // namespace platform

View File

@@ -38,15 +38,6 @@ private:
DISALLOW_COPY_AND_MOVE(ScopedDir);
};
class ScopedDirCleanup
{
std::string const m_fullPath;
public:
explicit ScopedDirCleanup(std::string const & path);
~ScopedDirCleanup();
};
std::string DebugPrint(ScopedDir const & dir);
} // namespace tests_support
} // namespace platform

View File

@@ -1506,9 +1506,10 @@ void QueryParams::ClearStreetIndices()
char const * arr[] = {
"a", "and", "s", "the", // English
"am", "an", "auf", "der", "im", "und", "zum", // German
"d", "da", "de", "del", "di", "du", "el",
"et", "la", "las", "le", "les", "los", "y", // French, Spanish, Italian
"в", "и", "на", "я" // Cyrillic
"as", "d", "da", "das", "de", "del", "di", "do",
"dos", "du", "e", "el", "et", "la", "las", "le",
"les", "los", "o", "os", "y", // French, Italian, Portuguese, Spanish
"в", "и", "на", "я" // Cyrillic
};
for (char const * s : arr)
m_strings.insert(NormalizeAndSimplifyString(s));

View File

@@ -339,8 +339,7 @@ void MapWidget::ShowInfoPopup(QMouseEvent * e, m2::PointD const & pt)
auto types = feature::TypesHolder(ft);
types.SortBySpec();
for (auto const & type : types.ToObjectNames())
concat = concat + type + " ";
concat = concat + "| " + DebugPrint(ft.GetGeomType());
concat += type + " ";
addStringFn(concat);
// Name

View File

@@ -8,6 +8,7 @@
#include "base/assert.hpp"
#include "base/logging.hpp"
#include <algorithm>
#include <functional>
#include <limits>
@@ -199,7 +200,7 @@ void UpdateDialog::OnItemClick(QTreeWidgetItem * item, int column)
case NodeStatus::Partly: st.DownloadNode(countryId); break;
case NodeStatus::InQueue:
case NodeStatus::Downloading: st.CancelDownloadNode(countryId); break;
case NodeStatus::Downloading: st.DeleteNode(countryId); break;
case NodeStatus::Applying:
// Do nothing.

View File

@@ -38,7 +38,7 @@ def multithread_run_if_one_country(func):
kwargs.update({"threads_count": settings.THREADS_COUNT})
# Otherwise index stage of Taiwan_* mwms continues to run after all other mwms have finished:
elif country == 'Taiwan_North':
kwargs.update({"threads_count": 6})
kwargs.update({"threads_count": 5})
elif country == 'Taiwan_South':
kwargs.update({"threads_count": 2})
func(env, country, **kwargs)

View File

@@ -31,22 +31,22 @@ python3 -m venv /tmp/venv
echo "<$(date +%T)> Copying map generator INI..."
cp var/etc/map_generator.ini.prod var/etc/map_generator.ini
$GENARGS=""
GENARGS=""
if [ $MWMTEST -gt 0 ]; then
if [ $MWMTEST == "true" ]; then
echo "Marking as a test (non-prod) generation"
# TODO: output test maps into e.g. osm-maps-test/ and use a different generation.log
$GENARGS="$GENARGS -s=test"
GENARGS="$GENARGS -s=test"
fi
if [ $MWMCONTINUE -gt 0 ]; then
if [ $MWMCONTINUE == "true" ]; then
echo "Continuing from preexisting generator run"
$GENARGS="$GENARGS --continue"
GENARGS="$GENARGS --continue"
fi
if [[ -n $MWMCOUNTRIES ]]; then
echo "Generating only specific maps for [$MWMCOUNTRIES]"
$GENARGS="$GENARGS --countries=$MWMCOUNTRIES"
GENARGS="$GENARGS --countries=$MWMCOUNTRIES"
fi
cd ~/comaps/tools/python

View File

@@ -46,6 +46,8 @@
394E1E0B22BBB5EB00E4BC75 /* utils.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 394E1E0922BBB5EB00E4BC75 /* utils.hpp */; };
39F376C0207D32450058E8E0 /* cities_boundaries_serdes_tests.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 39F376BE207D32410058E8E0 /* cities_boundaries_serdes_tests.cpp */; };
39F376C3207D32510058E8E0 /* scale_index_reading_tests.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 39F376C1207D324E0058E8E0 /* scale_index_reading_tests.cpp */; };
3D12E3D72111B4BE0015A9A9 /* caching_rank_table_loader.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3D12E3D52111B4BD0015A9A9 /* caching_rank_table_loader.cpp */; };
3D12E3D82111B4BE0015A9A9 /* caching_rank_table_loader.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 3D12E3D62111B4BD0015A9A9 /* caching_rank_table_loader.hpp */; };
3D489BC61D3D220F0052AA38 /* editable_map_object_test.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3D489BA71D3D1F8A0052AA38 /* editable_map_object_test.cpp */; };
3D489BC71D3D22150052AA38 /* features_vector_test.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3D489BA81D3D1F8A0052AA38 /* features_vector_test.cpp */; };
3D489BC81D3D22190052AA38 /* string_slice_tests.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3D489BA91D3D1F8A0052AA38 /* string_slice_tests.cpp */; };
@@ -269,6 +271,8 @@
394E1E0922BBB5EB00E4BC75 /* utils.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = utils.hpp; sourceTree = "<group>"; };
39F376BE207D32410058E8E0 /* cities_boundaries_serdes_tests.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = cities_boundaries_serdes_tests.cpp; sourceTree = "<group>"; };
39F376C1207D324E0058E8E0 /* scale_index_reading_tests.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = scale_index_reading_tests.cpp; sourceTree = "<group>"; };
3D12E3D52111B4BD0015A9A9 /* caching_rank_table_loader.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = caching_rank_table_loader.cpp; sourceTree = "<group>"; };
3D12E3D62111B4BD0015A9A9 /* caching_rank_table_loader.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = caching_rank_table_loader.hpp; sourceTree = "<group>"; };
3D452AF71EE6D9F5009EAB9B /* wheelchair_tests.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = wheelchair_tests.cpp; sourceTree = "<group>"; };
3D452AF81EE6D9F5009EAB9B /* feature_names_test.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = feature_names_test.cpp; sourceTree = "<group>"; };
3D452AF91EE6D9F5009EAB9B /* centers_table_test.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = centers_table_test.cpp; sourceTree = "<group>"; };
@@ -605,6 +609,8 @@
34664CEF1D49FEC1003D7096 /* altitude_loader.hpp */,
4088CE1F21AE993F00E2702A /* brands_holder.cpp */,
4088CE1E21AE993F00E2702A /* brands_holder.hpp */,
3D12E3D52111B4BD0015A9A9 /* caching_rank_table_loader.cpp */,
3D12E3D62111B4BD0015A9A9 /* caching_rank_table_loader.hpp */,
56C74C121C749E4700B71B9F /* categories_holder_loader.cpp */,
56C74C131C749E4700B71B9F /* categories_holder.cpp */,
56C74C141C749E4700B71B9F /* categories_holder.hpp */,
@@ -782,6 +788,7 @@
347F337D1C454242009758CC /* succinct_trie_builder.hpp in Headers */,
675341381A3F540F00A0A8C3 /* mwm_set.hpp in Headers */,
456E1B181F90E5B7009C32E1 /* cities_boundaries_serdes.hpp in Headers */,
3D12E3D82111B4BE0015A9A9 /* caching_rank_table_loader.hpp in Headers */,
670EE56D1B60033A001E8064 /* unique_index.hpp in Headers */,
675340FF1A3F540F00A0A8C3 /* cell_coverer.hpp in Headers */,
56C74C251C749E4700B71B9F /* search_string_utils.hpp in Headers */,
@@ -994,6 +1001,7 @@
6753410D1A3F540F00A0A8C3 /* drawing_rules.cpp in Sources */,
675341301A3F540F00A0A8C3 /* data_source.cpp in Sources */,
34664CF61D49FEC1003D7096 /* centers_table.cpp in Sources */,
3D12E3D72111B4BE0015A9A9 /* caching_rank_table_loader.cpp in Sources */,
6753414D1A3F540F00A0A8C3 /* types_mapping.cpp in Sources */,
34583BC71C88552100F94664 /* cuisines.cpp in Sources */,
675341121A3F540F00A0A8C3 /* feature_algo.cpp in Sources */,

View File

@@ -50,6 +50,8 @@
671ED38F20D403B300D4317E /* search_api_tests.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 671ED38A20D403B300D4317E /* search_api_tests.cpp */; };
674A29F01B26FD6F001A525C /* testingmain.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 674A29EE1B26FD5F001A525C /* testingmain.cpp */; };
674A2A2F1B26FF7B001A525C /* libmap.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 675345BB1A4054AD00A0A8C3 /* libmap.a */; };
674A2A361B27011A001A525C /* working_time_tests.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 674A2A351B27011A001A525C /* working_time_tests.cpp */; };
674A2A381B2715FB001A525C /* osm_opening_hours.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 674A2A371B2715FB001A525C /* osm_opening_hours.hpp */; };
674C38621BFF3095000D603B /* user_mark.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 674C385F1BFF3095000D603B /* user_mark.cpp */; };
675346481A4054E800A0A8C3 /* bookmark_manager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 675345D91A4054E800A0A8C3 /* bookmark_manager.cpp */; };
675346491A4054E800A0A8C3 /* bookmark_manager.hpp in Headers */ = {isa = PBXBuildFile; fileRef = 675345DA1A4054E800A0A8C3 /* bookmark_manager.hpp */; };
@@ -200,6 +202,8 @@
674A29CF1B26FCFE001A525C /* mwm_url_tests.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = mwm_url_tests.cpp; sourceTree = "<group>"; };
674A29DF1B26FD1C001A525C /* map_tests.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = map_tests.app; sourceTree = BUILT_PRODUCTS_DIR; };
674A29EE1B26FD5F001A525C /* testingmain.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = testingmain.cpp; path = ../../../libs/testing/testingmain.cpp; sourceTree = "<group>"; };
674A2A351B27011A001A525C /* working_time_tests.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = working_time_tests.cpp; sourceTree = "<group>"; };
674A2A371B2715FB001A525C /* osm_opening_hours.hpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.h; path = osm_opening_hours.hpp; sourceTree = "<group>"; };
674C385F1BFF3095000D603B /* user_mark.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = user_mark.cpp; sourceTree = "<group>"; };
675345BB1A4054AD00A0A8C3 /* libmap.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libmap.a; sourceTree = BUILT_PRODUCTS_DIR; };
675345D91A4054E800A0A8C3 /* bookmark_manager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = bookmark_manager.cpp; sourceTree = "<group>"; };
@@ -353,6 +357,7 @@
671ED38A20D403B300D4317E /* search_api_tests.cpp */,
674A29EE1B26FD5F001A525C /* testingmain.cpp */,
BB421D6A1E8C0026005BFA4D /* transliteration_test.cpp */,
674A2A351B27011A001A525C /* working_time_tests.cpp */,
ED49D74B2CEF3CE3004AF27E /* elevation_info_tests.cpp */,
ED85D1CF2D5F508700D8075D /* track_statistics_tests.cpp */,
);
@@ -427,6 +432,7 @@
45F6EE9B1FB1C77500019892 /* mwm_tree.hpp */,
675346051A4054E800A0A8C3 /* mwm_url.cpp */,
675346061A4054E800A0A8C3 /* mwm_url.hpp */,
674A2A371B2715FB001A525C /* osm_opening_hours.hpp */,
34583BCD1C88556800F94664 /* place_page_info.cpp */,
34583BCE1C88556800F94664 /* place_page_info.hpp */,
3DF528D5237DC82E000ED0D5 /* position_provider.hpp */,
@@ -513,6 +519,7 @@
6753469C1A4054E800A0A8C3 /* track.hpp in Headers */,
675346651A4054E800A0A8C3 /* framework.hpp in Headers */,
BBA014B120754997007402E4 /* user_mark_id_storage.hpp in Headers */,
674A2A381B2715FB001A525C /* osm_opening_hours.hpp in Headers */,
ED85D1CC2D5F4B5B00D8075D /* track_statistics.hpp in Headers */,
3DEE1ADF21EE03B400054A91 /* power_manager.hpp in Headers */,
F6D2CE7F1EDEB7F500636DFD /* routing_manager.hpp in Headers */,
@@ -664,6 +671,7 @@
FAA8387426BB3C0F002E54C6 /* countries_names_tests.cpp in Sources */,
679624B01D1017DB00AE4E3C /* gps_track_storage_test.cpp in Sources */,
674A29F01B26FD6F001A525C /* testingmain.cpp in Sources */,
674A2A361B27011A001A525C /* working_time_tests.cpp in Sources */,
679624B11D1017DB00AE4E3C /* gps_track_test.cpp in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;