Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit83a7fb8

Browse files
nodeSpace9prady9
authored andcommitted
Set OpenCL backend for opencl interop example
1 parent9334199 commit83a7fb8

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

‎opencl-interop/examples/ocl_af_app.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,9 @@ use arrayfire as af;
55
use ocl_core::{ContextProperties,Event};
66

77
fnmain(){
8+
// Set the arrayfire backend to use OopenCL first, because CUDA is the default
9+
af::set_backend(af::Backend::OPENCL);
10+
811
// Choose platform & device(s) to use. Create a context, queue,
912
let platform_id = ocl_core::default_platform().unwrap();
1013
let device_ids = ocl_core::get_device_ids(&platform_id,None,None).unwrap();

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp