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

Build OpenCL program as soon as the OpenCL device is initialized #293

Merged
merged 1 commit into from
Jul 9, 2015

Conversation

HenningJ
Copy link
Contributor

Before this, the OpenCL program was built when the first frame arrives and the following frames were dropped, because building the program takes a while.

With this change, the OpenCL program is built before the device is started. Then, when the first frame arrives, it only needs to be initialized, which is quite fast.

When the DepthPacketProcessor::Config changes, the OpenCL program might need to be re-initialized or even be rebuilt (depending on which config values were changed), but only the config actually changed. This is handled here as well.

@floe
Copy link
Contributor

floe commented Jun 17, 2015

Patch looks very sensible, on what platforms has this been tested so far?

@HenningJ
Copy link
Contributor Author

I just tested it on Windows

@floe floe added this to the 0.1 milestone Jun 24, 2015
@floe
Copy link
Contributor

floe commented Jun 24, 2015

Could you merge master into your opencl-build branch again? I don't think this is really a merge conflict, there just have been some minor changes within the OpenCL depth packet processor.

Before this, the program was built when the first frame arrives and the following frames were dropped, because building the program takes a while.
Now, the program is built before the device is started. When the first frame arrives, it only needs to be initialized, which is quite fast.
@HenningJ
Copy link
Contributor Author

Done. It was just one little throw.

@floe
Copy link
Contributor

floe commented Jul 9, 2015

Finally got around to testing on Ubuntu 14.04, works beautifully. Merged.

floe added a commit that referenced this pull request Jul 9, 2015
Build OpenCL program as soon as the OpenCL device is initialized
@floe floe merged commit 1d2db2a into OpenKinect:master Jul 9, 2015
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