Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8994779
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T23:30:22+00:00 2026-06-15T23:30:22+00:00

I used the codes from the following the website . But the problem I

  • 0

I used the codes from the following the website.

But the problem I am facing is getting the coordinates of my object.

Let me explain. According to the code. You just need to add your graphic images in PNG format and refer it to the class here. What I am trying to achieve is a simple collision detection mechanism. I have added a maze (as PNG). And have a object (as PNG) to go through the blank path within the maze. In order to do this I need to know the blank spaces within the coordinates through which my object will move.

Can any one tell me how to get the blank spaces as (x,y) coordinates through which I can take my object?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T23:30:23+00:00Added an answer on June 15, 2026 at 11:30 pm

    If there’s one entry and one exit to the maze, or an open area around the maze which contains the destination point for multiple entries or exits, the A search algorithm* will do the job:

    • Link

    • http://www.stackframe.com/software/PathFinder

    Note, that this might be best done on a CPU. You need to modify the condition for a path segment to handle the object size, a simple approach just assumes a path width of 1 image pixel.

    If you modify the algo in such a way, that it matches multiple destination points, it might work even smoother, without the need for an open area for exits (one entry to many exits). For multiple starting points or entries respectively, a modification may result in N runs and path comparison to find the shortest one (many entries to many exits), or a reverse search if just one exit exists (many entries to one exit), like for one entry to many exits. If paths of multiple destination points are required, just continue the search until all of them are found or the algorithm is ‘stalled’ and stops.

    UPDATE:

    Best and most flexible way might be using a physics library supporting various shape types, like spheres, arbitrary convex hulls, etc. For example, you could use the ‘bullet physics’ library to do collision detection only, without physics simulation (but why not?). Fragment based collision detection in 2D could be achieved using OpenGL occlusion queries, which tend to be faster for complex shapes.

    To integrate an image, you’d need to transform/scale it to sort of multiple wall objects in the coordinate space where the other shape is defined in.

    In short: Collision detection using vertex data of arbitrary shapes is pretty expensive, to develop and at runtime. This is where the collision shapes of the bullet library would help, as they are used to represent a simplified shape of the objects to be drawn.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've used the following code from this link. Getting signals from a MIDI port
The following code is used to fetch logs from app engine for further processing.
I have used the following code to pick up an image from phone's gallery:
I used the following code to remove script, link tags from my string, $contents='<script>inside
I've used the following code, taken from here , to create my own custom
I am using following code to get bitmap from url. This function is used
I used the code from http://www.rgagnon.com/javadetails/java-0580.html to get Motherboard Id, but the result is
I have used this code for extracting urls from web page.But in the line
I've got the following PHP code which is used for registering to a website.
I am using the following code to login to asp website but it doesnt

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.