Support

If you have a problem or need to report a bug please email : support@dsprobotics.com

There are 3 sections to this support area:

DOWNLOADS: access to product manuals, support files and drivers

HELP & INFORMATION: tutorials and example files for learning or finding pre-made modules for your projects

USER FORUMS: meet with other users and exchange ideas, you can also get help and assistance here

NEW REGISTRATIONS - please contact us if you wish to register on the forum

Users are reminded of the forum rules they sign up to which prohibits any activity that violates any laws including posting material covered by copyright

converting bitmap graph to wavetable

For general discussion related FlowStone

converting bitmap graph to wavetable

Postby tester » Sat May 11, 2013 6:24 pm

Sometimes there are situations, when you have no way to get text data, but graphs are available. Graphs, that can be cleaned (to single curve on white rectangle) and converted to B/W.

So the question. DiD anyone played with that topic? Converting bitmap graphs into shape data for avetables? Solved issues of "thick lines", to get smooth "vector"?

p.s.: I'm duplicating this topic from SM forum, because I'm not sure who is where.
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
tester
 
Posts: 1786
Joined: Wed Jan 18, 2012 10:52 pm
Location: Poland, internet

Re: converting bitmap graph to wavetable

Postby strangeChild » Sat May 11, 2013 7:25 pm

Unless you're talking about hundreds of waves it's likely easier to trace them by eye over the image... a FS/SM type image file display with a draw-over feature that output a float array would be a (relative) no-brainer...

Recognizing scale and lines (and ignoring noise and other irrelevancies) from raw image data would be a major programming project (IMHO).
strangeChild
 
Posts: 47
Joined: Sat Apr 27, 2013 8:04 pm

Re: converting bitmap graph to wavetable

Postby strangeChild » Sat May 11, 2013 7:34 pm

Thought about it some more... it would be feasible and not that huge a project provided the function line was defined for all pixels across the horizontal range and you're ok with normalized data as output and there was no junk in the image. You can scan downward (increasing value) in each column looking for the first pixel above some threshold and record it's vertical position. Populate an array and then invert (for drawing position convention), scale (resample), and normalize.
strangeChild
 
Posts: 47
Joined: Sat Apr 27, 2013 8:04 pm

Re: converting bitmap graph to wavetable

Postby tester » Sat May 11, 2013 9:07 pm

FSM example?
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
tester
 
Posts: 1786
Joined: Wed Jan 18, 2012 10:52 pm
Location: Poland, internet

Re: converting bitmap graph to wavetable

Postby strangeChild » Sat May 11, 2013 9:48 pm

here's a draft... the normalization stuff isn't working the way I expect but you should get the idea... I used a min/max detect instead of a threshold for ease of programming (not done in Ruby!).

It's dreadfully slow because it's a double loop going through every pixel.
waveExtract.fsm
(6.72 KiB) Downloaded 854 times
strangeChild
 
Posts: 47
Joined: Sat Apr 27, 2013 8:04 pm

Re: converting bitmap graph to wavetable

Postby tester » Sat May 11, 2013 10:07 pm

Found this:
http://synthmaker.co.uk/forum/viewtopic ... 997#p91235

Generally I never played with graphics (yet), so the whole thing is new for me (...and it must wait until I finish other things), but as far I remember Trog wrote somewhere in the past also about averaging pixels for such detection, so the topic is "somewhere" (here or on SM forum). Plus i guess there will be something about interpolation (here or via resample module?).

In that one - I'm not against ruby. I just need (in the future) a small tool to convert (prepared) small bitmaps into 4k (or less) shapes for wavetabling.
Need to take a break? I have something right for you.
Feel free to donate. Thank you for your contribution.
tester
 
Posts: 1786
Joined: Wed Jan 18, 2012 10:52 pm
Location: Poland, internet

Re: converting bitmap graph to wavetable

Postby RJHollins » Fri Mar 28, 2014 7:56 am

Was wondering if any development came about on this idea ??

I'm finding a situation that I'd like to convert an image of a graph to a vector display to save space.
Here is an example of the typical image:
VSTAnalyzer [3Dent].jpg
VSTAnalyzer [3Dent].jpg (33.52 KiB) Viewed 12340 times

[was a BMP ... had to convert to JPG to post.]

In vector form, I had thought I could alter the scaling [size] and still maintain clarity for display.
RJHollins
 
Posts: 1571
Joined: Thu Mar 08, 2012 7:58 pm


Return to General

Who is online

Users browsing this forum: No registered users and 49 guests