added small example video
This commit is contained in:
BIN
assets/video.gif
Normal file
BIN
assets/video.gif
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 14 MiB |
@@ -13,6 +13,8 @@ float4 white_light(float4 input, float3 light, int3 mask) {
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
__kernel void min_kern(
|
||||
global char* map,
|
||||
global int3* map_dim,
|
||||
@@ -62,6 +64,8 @@ __kernel void min_kern(
|
||||
// for all 3 axis XYZ.
|
||||
float3 intersection_t = delta_t * offset;
|
||||
|
||||
// for negative values, wrap around the delta_t, rather not do this
|
||||
// component wise, but it doesn't appear to want to work
|
||||
if (intersection_t.x < 0) {
|
||||
intersection_t.x += delta_t.x;
|
||||
}
|
||||
@@ -86,7 +90,7 @@ __kernel void min_kern(
|
||||
do {
|
||||
|
||||
mask = intersection_t.xyz <= min(intersection_t.yzx, intersection_t.zxy);
|
||||
float3 thing = delta_t * fabs(convert_float3(mask.xyz));
|
||||
|
||||
intersection_t += delta_t * fabs(convert_float3(mask.xyz));
|
||||
voxel.xyz += voxel_step.xyz * mask.xyz;
|
||||
|
||||
|
||||
@@ -68,7 +68,7 @@ int Camera::update(double delta_time) {
|
||||
|
||||
// so vector multiplication broke?
|
||||
// have to do it component wise
|
||||
double multiplier = 10;
|
||||
double multiplier = 40;
|
||||
|
||||
position.x += movement.x * delta_time * multiplier;
|
||||
position.y += movement.y * delta_time * multiplier;
|
||||
|
||||
Reference in New Issue
Block a user