Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added a feature for tracing bitmap images #1872

Merged
merged 1 commit into from
May 6, 2022

Conversation

breiler
Copy link
Collaborator

@breiler breiler commented Apr 29, 2022

Added a new feature for tracing bitmaps to vector graphics. Here is a small demo on how to import a image and adjust different settings to get a nice vectorized image:
image_tracing

I am using the class imagetracerjava by András Jankovics (@jankovicsandras)

The settings works as the following:

  • Number of layers - this will try to separate a number of colors to different layers. The minimum is two.
  • Color range - Filters which colors to work with - essentially this will brighten or darken the image, cutting off darker or lighter colors to work with.
  • Color quantization - the defined number of layers will generate a color palette to use. This value will force near colors to that palette
  • Smooth lines - If a line segment is jagged or will contain many points this setting will smoothen those lines out.
  • Smooth curves - If curve segments are short, this setting will try to even those out making longer smother curves
  • Filter noise - if there are many fine grained details creating small objects this setting will filter those out
  • Blur radius - how large area in pixels that should be blurred. This setting can help to filter out noise or make lines smoother.
  • Blur delta - how much of the pixels in the blur area should be blurred

@codecov-commenter
Copy link

Codecov Report

Merging #1872 (8a7b47b) into master (da160cc) will decrease coverage by 0.43%.
The diff coverage is 0.00%.

@@             Coverage Diff              @@
##             master    #1872      +/-   ##
============================================
- Coverage     18.27%   17.83%   -0.44%     
+ Complexity     1945     1943       -2     
============================================
  Files           709      716       +7     
  Lines         29775    30488     +713     
  Branches       2353     2484     +131     
============================================
- Hits           5440     5439       -1     
- Misses        23878    24592     +714     
  Partials        457      457              
Impacted Files Coverage Δ
...inder/ugs/nbp/designer/actions/SubtractAction.java 0.00% <0.00%> (ø)
...der/ugs/nbp/designer/actions/TraceImageAction.java 0.00% <0.00%> (ø)
...nder/ugs/nbp/designer/entities/AbstractEntity.java 70.70% <0.00%> (-2.21%) ⬇️
...a/com/willwinder/ugs/nbp/designer/gui/ToolBox.java 0.00% <0.00%> (ø)
...bp/designer/gui/imagetracer/ImageTracerDialog.java 0.00% <0.00%> (ø)
...er/ugs/nbp/designer/gui/imagetracer/SVGCanvas.java 0.00% <0.00%> (ø)
...gs/nbp/designer/gui/imagetracer/TraceSettings.java 0.00% <0.00%> (ø)
...p/designer/gui/imagetracer/TraceSettingsPanel.java 0.00% <0.00%> (ø)
...r/ugs/nbp/designer/gui/imagetracer/TraceUtils.java 0.00% <0.00%> (ø)
.../willwinder/ugs/nbp/designer/io/svg/SvgReader.java 0.00% <0.00%> (ø)
... and 7 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0f60799...8a7b47b. Read the comment docs.

@breiler breiler merged commit 9f77047 into winder:master May 6, 2022
@IIIKOYOTIII IIIKOYOTIII linked an issue May 9, 2022 that may be closed by this pull request
@breiler breiler deleted the feature/image-tracer branch December 21, 2022 05:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Vvv
2 participants