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

Dynamically load GEOSPreparedContainsXY where available #4

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dbaston
Copy link
Contributor

@dbaston dbaston commented Sep 13, 2022

This is my attempt to update geos-performance so we can look at how libgeos/geos#674 affects point-in-polygon performance assuming that client code is updated to use GEOSPreparedContainsXY.

It works well for me and gives the desired "no impact on performance" answer. I don't know what you think about the complexity it adds, or how if this code even runs on MacOS. But I think this presents an alternative to the "only use functions available in the oldest version you want to test" limitation.

log_stderr("VERSION [GEOS %s]\n", GEOSversion());

geos_lib_handle = dlopen("libgeos_c.so", RTLD_LAZY);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, will need to do something about file extensions, "libgeos_c.dylib" is what I've got. There is a dlopen() documented so that part might work. I will experiemnt.

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.

2 participants