https://github.com/brosnanyuen/raybnn_raytrace
Ray tracing library using GPUs, CPUs, and FPGAs via CUDA, OpenCL, and oneAPI
https://github.com/brosnanyuen/raybnn_raytrace
arrayfire cuda gpu gpu-computing opencl parallel parallel-computing ray ray-tracing raybnn raylib raytracer raytracing rust
Last synced: 10 months ago
JSON representation
Ray tracing library using GPUs, CPUs, and FPGAs via CUDA, OpenCL, and oneAPI
- Host: GitHub
- URL: https://github.com/brosnanyuen/raybnn_raytrace
- Owner: BrosnanYuen
- License: gpl-3.0
- Created: 2023-10-05T22:34:33.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-06-18T06:03:53.000Z (almost 2 years ago)
- Last Synced: 2025-05-11T16:05:02.406Z (about 1 year ago)
- Topics: arrayfire, cuda, gpu, gpu-computing, opencl, parallel, parallel-computing, ray, ray-tracing, raybnn, raylib, raytracer, raytracing, rust
- Language: Rust
- Homepage:
- Size: 148 KB
- Stars: 4
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# RayBNN_Raytrace
Ray tracing library using GPUs, CPUs, and FPGAs via CUDA, OpenCL, and oneAPI
Raytraces intersections between rays, spheres, circles
# Install Arrayfire
Install the Arrayfire 3.9.0 binaries at [https://arrayfire.com/binaries/](https://arrayfire.com/binaries/)
or build from source
[https://github.com/arrayfire/arrayfire/wiki/Getting-ArrayFire](https://github.com/arrayfire/arrayfire/wiki/Getting-ArrayFire)
# Add to Cargo.toml
```
arrayfire = { version = "3.8.1", package = "arrayfire_fork" }
rayon = "1.10.0"
num = "0.4.3"
num-traits = "0.2.19"
half = { version = "2.4.1" , features = ["num-traits"] }
RayBNN_DataLoader = "2.0.3"
RayBNN_Sparse = "2.0.2"
RayBNN_Cell = "2.0.3"
RayBNN_Raytrace = "2.0.3"
```
# List of Examples
# Line Sphere Intersection
```
RayBNN_Raytrace::Intersect::Sphere::line_sphere_intersect(
&start_line,
&dir_line,
&circle_center,
&circle_radius,
&mut intersect
);
```
# Line Sphere Intersection Batch
```
RayBNN_Raytrace::Intersect::Sphere::line_sphere_intersect_batch(
3,
&start_line,
&dir_line,
&circle_center,
&circle_radius,
&mut intersect
);
```
# Line Sphere Intersection Batch V2
```
RayBNN_Raytrace::Intersect::Sphere::line_sphere_intersect_batchV2(
3,
1,
&circle_center,
&circle_radius,
&mut start_line,
&mut dir_line,
&mut input_idx,
&mut hidden_idx,
);
```
# Raytrace Neural Connections using RT3
```
RayBNN_Raytrace::Tracing::RT3::RT3_distance_limited_directly_connected(
&modeldata_float,
&modeldata_int,
&glia_pos,
&input_pos_total,
&input_idx_total,
&hidden_pos_total,
&hidden_idx_total,
&mut WRowIdxCOO,
&mut WColIdx
);
```