~pocl/pocl/trunk

« back to all changes in this revision

Viewing changes to lib/kernel/vecmathlib-pocl/fast_distance.cl

  • Committer: Erik Schnetter
  • Date: 2013-08-17 16:11:57 UTC
  • Revision ID: eschnetter@perimeterinstitute.ca-20130817161157-pco7u3hv98nbg2uk
Move pocl-specific Vecmathlib code into a separate subdirectory

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
__attribute__((__overloadable__))
 
2
float fast_distance(float p0, float p1)
 
3
{
 
4
  return fast_length(p0-p1);
 
5
}
 
6
 
 
7
__attribute__((__overloadable__))
 
8
float fast_distance(float2 p0, float2 p1)
 
9
{
 
10
  return fast_length(p0-p1);
 
11
}
 
12
 
 
13
__attribute__((__overloadable__))
 
14
float fast_distance(float3 p0, float3 p1)
 
15
{
 
16
  return fast_length(p0-p1);
 
17
}
 
18
 
 
19
__attribute__((__overloadable__))
 
20
float fast_distance(float4 p0, float4 p1)
 
21
{
 
22
  return fast_length(p0-p1);
 
23
}