Closed maerki closed 2 weeks ago
The changes introduced in this pull request primarily enhance the functionality and structure of various classes related to map rendering and camera management. Key additions include new methods for retrieving scaling factors in multiple interfaces, improved buffer management in rendering classes, and enhancements to error handling and thread safety. The modifications span across multiple files, including both Java and C++ implementations, as well as Swift files, reflecting a comprehensive update to the rendering pipeline and camera interface.
File Path | Change Summary |
---|---|
bridging/android/java/io/openmobilemaps/mapscore/shared/map/MapCameraInterface.kt |
Added abstract fun getScalingFactor(): Double in MapCameraInterface ; implemented in CppProxy . |
bridging/android/jni/map/NativeMapCameraInterface.cpp |
Added CJNIEXPORT jdouble JNICALL Java_io_openmobilemaps_mapscore_shared_map_MapCameraInterface_00024CppProxy_native_1getScalingFactor(JNIEnv* jniEnv, jobject /*this*/, jlong nativeRef) method. |
bridging/ios/MCMapCameraInterface+Private.mm |
Added - (double)getScalingFactor method. |
bridging/ios/MCMapCameraInterface.h |
Added - (double)getScalingFactor; method. |
djinni/map/core.djinni |
Added get_scaling_factor() : f64 method. |
ios/graphics/Model/BaseGraphicsObject.swift |
Updated originOffsetBuffer to originOffsetBuffers ; added vpMatrixBuffers and mMatrixBuffers ; updated method signatures for clarity. |
ios/graphics/Model/Icosahedron/Icosahedron.swift |
Updated render methods for vertex matrix handling using new buffer management. |
ios/graphics/Model/Line/LineGroup2d.swift |
Updated buffer handling and error checking in render and setLines methods. |
ios/graphics/Model/MultiBuffer.swift |
Added MultiBuffer<DataType> struct and methods for managing multiple Metal buffers. |
ios/graphics/Model/Polygon/Polygon2d.swift |
Added mMatrixBuffers ; updated rendering methods for new buffer management. |
ios/graphics/Model/Polygon/PolygonGroup2d.swift |
Updated render and setVertices methods for improved buffer management. |
ios/graphics/Model/Polygon/PolygonPatternGroup2d.swift |
Updated render and setVertices methods for new buffer handling. |
ios/graphics/Model/Quad/Quad2d.swift |
Added mMatrixBuffers ; updated rendering logic for vertex data management. |
ios/graphics/Model/Quad/Quad2dInstanced.swift |
Replaced originBuffer with originBuffers ; added mMatrixBuffers . |
ios/graphics/Model/Quad/Quad2dStretchedInstanced.swift |
Introduced new buffer handling for vertex matrices and origin offsets. |
ios/graphics/Model/Text/Text.swift |
Introduced vpMatrixBuffer for vertex matrix data management; updated error handling. |
ios/graphics/Model/Text/TextInstanced.swift |
Replaced individual buffers with MultiBuffer instances for better management. |
ios/graphics/RenderingContext.swift |
Added public static let bufferCount = 3 and private(set) var currentBufferIndex = 0 ; added public func beginFrame() method. |
ios/maps/MCMapView.swift |
Added private var renderSemaphore = DispatchSemaphore(value: 3) for rendering synchronization. |
shared/public/MapCameraInterface.h |
Added virtual double getScalingFactor() = 0; method. |
shared/public/Tiled2dMapSourceImpl.h |
Reformatted method signatures for readability; no logic changes. |
shared/src/map/camera/MapCamera3d.cpp |
Improved organization and refined logic for camera movements; added coordinateConversionHelper . |
shared/src/map/camera/MapCamera3d.h |
Added void updateMatrices() ; adjusted method signatures for consistency. |
shared/src/map/layers/tiled/vector/symbol/Tiled2dMapVectorSourceSymbolDataManager.cpp |
Updated scaleFactor calculations and refined layer update logic. |
In the world of maps, we hop and play,
With scaling factors brightening the way.
Buffers are managed, errors are tamed,
In our rendering realm, nothing's the same!
Hooray for the changes, let’s leap and cheer,
For every new feature brings us more near! 🐇✨
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
Summary by CodeRabbit
New Features
getScalingFactor()
across various classes, enhancing functionality for retrieving scaling factors relevant to rendering and camera adjustments.renderSemaphore
inMCMapView
for improved rendering control through semaphore-based synchronization.Bug Fixes
Refactor
MultiBuffer
for efficient data handling.MapCamera3d
, enhancing clarity and maintainability.Tiled2dMapVectorSourceSymbolDataManager
for improved rendering efficiency.