Releases: BlizzCrafter/MonoGame.SplineFlower
Releases · BlizzCrafter/MonoGame.SplineFlower
Chain Splines Performance Boost!
ADDED:
- InitializeSplineControlSample() added so that corresponding SplineSampleControls are getting correctly re-initialized after tab page switches.
- Added TangentColor to better seperate it from the rest of the spline colors.
- The solution now supports Visual Studio 2022.
CHANGED:
- It's now possible to add a float factor value to the Add/Substract Tension and Bias functions of the HermiteSpline type.
- Changed the default spline generation function "Reset()" to form a "C" symbol instead of a "Z" symbol now by default.
- The HermiteSplineControl sample now shows more possibilites of creating a custom HermiteSpline using Tension, Bias and modifying Tangents just by code (programmatically).
- Only Rotate, Scale and ScaleRotate if the value is not 0.
- Calling SetSplineMarkerResolution() also updates the SplineStepDistance from now on, which gives a huge performance boost when drawing curves of splines.
- Applied modifications to the ChainSplineControl project to enable performance tests in the ChainSplineControl.
- CenterSplineColor is now Magenta for better visibility.
- Updated the MonoGame version of all projects.
- Updated nuspec files and nuget packages.
FIXED:
- FindNearestPoint fixed end of spline wasn't detected correctly - by adding a small value to the MaxProgress() function.
Chain Splines!
ADDED:
- Added a new ChainSplineControl to the project.
- Points of a spline are now calculating their neighbours (Left & Right).
- It's possible to translate a specific Transform now instead of all or just the selected one.
- Added a recursive chain-logic to enable the dynamic movement of control points (Transforms) of a spline, based on user input like mouse movement.
- The chain translation of Transforms can now happen in the inverse direction, which affects the direct neighbours of the corresponding Transform (middle point).
- Added
EndPointColor
andEndPointThickness
to the Setup class.
-- Also changed theStartPointColor
from Magenta to White.
-- TheEndPointColor
is Black, so the user can easily determine if such a specific point is the start or the end of a spline.
CHANGED:
- Changed the display text of the PolygonSplineControl to PolygonSpline.
- Changed internal Transform.Translate() to public. This gives more fine control over Transforms - espacially useful to programmatically control the tangents of a HermiteSpline (NOTE: Will be reverted in the next update and exchanged with an overridable virtual function)
- The difference between TranslatePointFirstClick and current mouse location is now stored as "Acceleration" inside a spline. This is useful in ChainSplines.
- The index of a Point is now set when a Transform/Tangent/Point is beeing created instead of in the draw loop.
- Updated AssemblyInfo, LicenseYear and TwitterLink.
- Adjusted PointColor and PointThickness, so that it is more homogeneous.
- Simplified the drawing of a spline, by moving the calculations of the angle and distances between points to the
DrawPoint()
andDrawLine()
methods. - Removed the Tank-SplineWalker from the project and added an advanced version of the Car-SplineWalker instead.
- A spline gets drawn with
Spline.Draw()
now instead ofSpline.DrawSpline()
.
FIXED:
- Fixed a bug with "Transform.Size" beeing wrong after translation.
Complete Overhaul + Hermite Splines!
Breaking Changes: this update is not compatible with older versions of this library!
- Added the missing "AddCurveRight" override in the HermiteSpline class.
- Initial setup initialization in all sample controls.
- Added a new PolygonTextureTest spline and texture called "RaceTrack.json" (CatMulRomSpline) and "roadTexture.png" (Texture2D).
- Added more possibilities of showing or hiding specific elements of a spline (Lines, Points).
- The selected tangent text is now drawn directly inside the HermiteSplineControl instead as a forms label.
- The game project now includes spline json data generated with the revised MonoGame.SplineFlower library update. It defaults to the HermiteSpline test now and loads it as an xnb file with the ContentManger to show that it can handle the latest additions and changes to the library and the pipeline.
- Updated the samples project to work with the new MonoGame.SplineFlower update.
- Based on the revised library update the MonoGame.SplineFlower.Content.Pipeline library now reflects the latest changes and additions.
- New spline type: HermiteSpline! (basically a CatMulRomSpline but with "Bias" & "Tension" parameters as well as moveable Tangents, which gives more precise control over the curve of this spline.
- Complelty revised the MonoGame.SplineFlower library and gave it more structure and encapsulation, which makes it way easier now to understand and use the library as well as adding new spline types.
- Updated AssemblyInfo
- Solution upgraded to support Visual Studio 2019
Polygon Stripes Feature!
- It's now possible to change the CatMulRom-State of a spline anytime (vice-versa).
- The setup class now initializes 3D graphics related stuff for the new PolygonStripeControl.
- Added road texture and road spline json data.
- Reworked the TransformControl to return WorldUnits if wished.
- Removed old Functions class and added new Utils project to the solution.
Find Nearest Point on Spline Feature!
- Added FindNearestPointOnSpline feature and sample project.
- Added "Extensions class" to support spriteBatch overloads with additional drawing capabilities.
- Added a test Transform in the TransformControl to have a dummy transform for additional user interaction in the sample projects.
- It's now possible to adjust the accuracy of the FindNearestPoint function from within the sample control.
- The GitHub-Release rar-file now containing not only the lib binaries but also the editor and sample projects - already pre-compiled, so that the user can directly start and run the samples or the editor; **no compilation needed! **
Rotate, Scale, ScaleRotate, CenterTransform
- Renamed ShowBezierSpline to ShowSpline.
- Added ShowCenterTransform to make it possible to hide or show the transform in the center of the spline.
- Only calculating the CenterTransform when necessary.
- It's now possible to programmatically create a spline by using the new constructor.
- Added CenterTransformMode "None". On this mode the whole spline can be moved by dragging the CenterSpline with the left mouse button.
- Fixed that points which could be placed exactly at the start point (index 0) could resulting in wrong calculations.
- After importing a spline the newly imported spline will be placed on the center of the screen.
- Added NuGetRelease configuration so that if building in Release configuration, it wouldn't result in compilation errors on the users end, because of the post build commands.
- It's now possible to change the CenterTransformMode (Rotate, Scale, ScaleRotate) in the Sample- and Editor project.
- Fixed IndexOutOfRangeException when the CurrentTriggerIndex was -1 in the SplineWalker class.
- Added additional NullReference checks for the splineControl and the splineControl.MySplineWalker.
- It's now possible to scale the whole spline by dragging the CenterSpline transform with the left mouse button.
- It's now possible to rotate and scale-rotate the whole spline.
- Added public bool IsCenterSpline to check if a Transform is the center of the spline or not.
- Renamed GetSplineCenter to CenterSpline.
- Added checks to determine if a Transform is a point on a spline or the CenterTransform.
- Removed LineControl sample and CurveControl sample from the project.
- Extended GameSample to demonstrate new features.
CatMulRomSplines!
- Added support for CatMulRomSplines.
- Added public static float SplineStepDistance so that the user can easily get the current step resolution of a specific spline.
- Added a SplineWalker to CatMulRom sample and looping the spline track.
- Direction vectors for CatMulRom splines have now the correct rotation / angle.
- Added possibility of showing or hideing the curves of a CatMulRomSpline.
- Json serialization updated accordingly.
- ContentPipeline support.
- Editor updated accordingly.
- Updated Readme.md file.
Advanced Controls (Keyboard and GamePad)
- It's now possible to have Keyboard and GamePad input at the same time.
- It's now possible to add multiple keys or buttons to the SplineWalker; just one of those buttons can be pressed at the same time.
- Renamed AlreadyTriggered to CanTrigger in the SplineWalker class.
- Made sure that we have the _currentTriggerIndex value higher than -1 to avoid out of range bugs.
- Fixed a bug where the current trigger index went wrong when quickly changed the walking direction.
- Added Tank class (SplineWalker) and TankTrack BezierSpline to show the new input features.
- It's now possible to control a SplineWalker with a Keyboard and a GamePad.
- Renamed Mode to WalkerMode in the SplineWalker class.
- A SplineWalker can now trigger events in different directions. For example only when he travels forward, backward or forward and backward.
- A SplineWalker can now perform a turn (rotating 180 degrees) when walking in the opposite direction (PingPong WalkingMode).
- Added new sample project AdvancedControls.cs