Page 2 of 3

Re: Rapid Object Mapping

Posted: Sat Oct 25, 2025 9:38 pm
by JHPJHP
To put a nail in this.

Some earlier comments questioned the effectiveness of the scripts, even though my previous posts and demonstration videos already showed that they were capable of what was being discussed.

The examples in the complete package demonstrate a range of capabilities, including extracting contour points from an image, displaying the points directly or saving them to an SVG file, importing and exporting the extracted X/Y coordinate points to a database and DataSection, and animating the points through vector graphics using images from both a sprite sheet and a GIF file.

Re: Rapid Object Mapping

Posted: Wed Oct 29, 2025 12:34 am
by JHPJHP
Morph Shapes

I debated whether to post this here or start a new topic. Originally, this feature was intended as part of Rapid Object Mapping, but as development progressed, it evolved into a standalone concept.

Currently, four base shapes are available: Circle, Square, Star, and Random, but any two point arrays should work.

Thanks to a wide range of user-configurable parameters, these core shapes can be transformed into numerous additional forms. The morphing process is driven by independent algorithms, allowing almost any shape to morph into any other, and vice versa.

Six example morphs are demonstrated in the following video, each of which are toggled between line and point representations. This provides an alternative way to visualize the morphing process and supports a more detailed morph analysis.

Watch the video here: Morph Shapes

Re: Rapid Object Mapping

Posted: Wed Oct 29, 2025 3:57 am
by idle
Neat. I'm still thinking about that for the AVGSceneGraph but while I still have issues with the Bezier polygon function I haven't gotten around to doing it.

Re: Rapid Object Mapping

Posted: Wed Oct 29, 2025 9:35 am
by acreis
JHPJHP wrote: Fri Oct 24, 2025 3:01 pm
Important Update Regarding Project Releases:
With the latest version of PureBasic, I have implemented hundreds of updates and enhancements across my various projects. However, since PureBasic is still in beta, most of the updated projects will not be published on my website until the final release becomes available.
Sorry JHPJHP and all folks for writing here about another subject, I couldn't write in the proper topic.
Thanks JHPJHP by the hard work, I'm a proud key holder.
About BlurBehindWindow, would it be possible create a borderless captionless transparent window?
I tried, but it seems the code fail unless the window have borders.
The purpose is create a semitransparent window over another control to highlight some information.
I know about the old layered window, but it makes the text underneath look faded.
The transparent window created by BlurBehind effect is a lot better!

Thanks in advance by any help, JHPJHP!

Re: Rapid Object Mapping

Posted: Wed Oct 29, 2025 2:51 pm
by AAT
JHPJHP wrote: Wed Oct 29, 2025 12:34 am Morph Shapes
....
Hello, my friend!
Once again, I needed to process webcam video (to find the coordinates of a circular PnP machine nozzle imprint on paper), and once again, I turned to your OpenCV example package. I immediately found a suitable example, and I easily solved the problem. Once again, I want to thank you for the enormous work you've done! Your multitude of systematic examples is brilliant!
Thank you so much!

P.S. I apologize for writing off-topic, but I couldn't find another way to send you message.

Re: Rapid Object Mapping

Posted: Wed Oct 29, 2025 6:29 pm
by JHPJHP
Hi idle,

Just a fun script to keep me motivated. I’ll probably incorporate it into ROM when time permits.

Your new project is coming along nicely. It’s one of those things where the possibilities are endless.

---------------------------

Hi acreis,

I just spent an hour trying to get DWM Blur Behind Window (transparency) to work on a borderless, captionless window, but in their infinite wisdom, Microsoft does not support it. I even tried a workaround where a child window is attached to a borderless window, with the caption and borders moved outside the visible area, but unfortunately, child windows are not supported either.

You already know this, but for others it may provide some context.

Code: Select all

Enumeration
  #MainWindow
  #CalendarGadget
  #TransparentWindow
EndEnumeration

If OpenWindow(#MainWindow, 0, 0, 800, 600, "Main Window", #PB_Window_SystemMenu | #PB_Window_ScreenCentered)
  CalendarGadget(#CalendarGadget, 100, 100, 300, 100)
  SetWindowColor(#MainWindow, $FFFFFF)
  nFlags = #PB_Window_BorderLess | #PB_Window_Invisible | #PB_Window_NoActivate

  If OpenWindow(#TransparentWindow, 50, 50, 400, 200, #Null$, nFlags, WindowID(#MainWindow))
    SetParent_(WindowID(#TransparentWindow), WindowID(#MainWindow))
    SetWindowColor(#TransparentWindow, $00FFFF)
    SetWindowLongPtr_(WindowID(#TransparentWindow), #GWL_EXSTYLE, #WS_EX_LAYERED | #WS_EX_TRANSPARENT)
    SetLayeredWindowAttributes_(WindowID(#TransparentWindow), #Null, 20, #LWA_ALPHA)
    DisableWindow(#TransparentWindow, #True)
    HideWindow(#TransparentWindow, #False)
  EndIf
  SetForegroundWindow_(WindowID(#MainWindow))
  Repeat : Until WaitWindowEvent() = #PB_Event_CloseWindow
EndIf
---------------------------

Hi AAT,

It’s always a pleasure hearing from you.

I am glad I’m not the only one still finding use in our OpenCV project. We both invested so much time into it, truly a labor of love.

I have many project ideas involving OpenCV, and with over 250 examples, there is no shortage of inspiration.

Thank you, my friend, for taking the time to share your latest endeavor with me.

Re: Rapid Object Mapping

Posted: Thu Oct 30, 2025 11:58 pm
by JHPJHP
Hi All,

Although the results from ROM are impressive, I believed there was still room for improvement. Initially, I assumed this enhancement would come from OpenCV; however, a recent post by pf shadoko showcasing a simple spline algorithm prompted me to reconsider my approach.

I've added a new example that includes five spline Procedures:
• AddPathCatmullRom
• AddPathKochanekBartels
• AddPathBSpline
• AddPathMonotone2D
• AddPathPfShadoko

Note: The improvements are subtle; achieving these results required a reduction in the number of points returned by the OpenCV algorithm.

Re: Rapid Object Mapping

Posted: Fri Oct 31, 2025 4:47 pm
by JHPJHP
I’ve just added another example, which might be my last, though it’s always interesting to see where these projects lead.

By leveraging the algorithms from Morph Shapes, the effect shown in the following video was a straightforward merging of examples.

I also slowed the morph transitions and extended the pauses between images to better highlight the quality and precision of the algorithms.

Watch the video here: Morph Horse Spider

Re: Rapid Object Mapping

Posted: Sat Nov 01, 2025 8:50 am
by IceSoft

Re: Rapid Object Mapping

Posted: Mon Nov 03, 2025 12:56 am
by JHPJHP
Rapid Object Mapping

If you’ve seen the videos from my previous posts, you may have noticed the morphing examples. While visually impressive, those examples were limited to morphing between two single lists of contour points. This new example expands the functionality, supporting morphs from single to single, single to multiple, multiple to single, and three versions of multiple to multiple.

In the animated GIF below, the Spider image is generated from a single contour list containing over 300 points, while the PureBasic image is composed of 45 separate contour lists, totaling more than 2,000 points.

Note: These points were generated instantly from two images and stored in both a DataSection and a database using the ROM scripts.

Image

Re: Rapid Object Mapping

Posted: Sun Nov 09, 2025 11:28 pm
by JHPJHP
The range of applications for extracted X/Y points from an image is becoming increasingly apparent, as illustrated by the following new example:

Image

Re: Rapid Object Mapping

Posted: Thu Nov 13, 2025 11:46 pm
by JHPJHP
Before I shelf this project, I wanted to incorporate another visual feature, gradient colors with various effects.

Image

Re: Rapid Object Mapping

Posted: Fri Nov 14, 2025 4:23 am
by idle
That's pretty neat.

Re: Rapid Object Mapping

Posted: Fri Nov 14, 2025 5:39 pm
by JHPJHP
Hi idle,

I always appreciate you taking the time to post, knowing you have a solid grasp of what you’re looking at.

There are countless potential applications for ROM, and I can easily see myself disappearing down the rabbit hole again. Once I built the scripts to extract contour points and began producing examples, the project quickly took on a life of its own.

At the moment, there are 24 examples, and nearly every component of each one is interchangeable. Although there are many possible directions to explore, the most logical next step would be to consolidate the work into a structured framework or library. For now, though, I plan to step back from contour points and focus on continuing improvements to some of my other projects.

Re: Rapid Object Mapping

Posted: Sat Nov 15, 2025 10:07 pm
by JHPJHP
Rapid Object Mapping

Ok, one more demonstration.

Applying a static image as a background texture was straightforward...

Image

... But synchronizing the background texture with the animated X/Y coordinates required a bit more effort.
• This is a general-purpose method for applying a texture to a list of animated contour points.

Image