godot/thirdparty/embree/kernels/geometry/curve_intersector_ribbon.h

// Copyright 2009-2021 Intel Corporation
// SPDX-License-Identifier: Apache-2.0

#pragma once

#include "../common/ray.h"
#include "quad_intersector.h"
#include "curve_intersector_precalculations.h"

#define Bezier1Intersector1
#define Bezier1IntersectorK

namespace embree
{
  namespace isa
  {
    template<typename NativeCurve3ff, int M>
    struct RibbonHit
    {};

    /* calculate squared distance of point p0 to line p1->p2 */
    template<int M>
    __forceinline std::pair<vfloat<M>,vfloat<M>> sqr_point_line_distance(const Vec2vf<M>& p0, const Vec2vf<M>& p1, const Vec2vf<M>& p2)
    {}
    
    /* performs culling against a cylinder */
     template<int M>
     __forceinline vbool<M> cylinder_culling_test(const Vec2vf<M>& p0, const Vec2vf<M>& p1, const Vec2vf<M>& p2, const vfloat<M>& r)
    {}

    template<int M = VSIZEX, typename NativeCurve3ff, typename Epilog>
    __forceinline bool intersect_ribbon(const Vec3fa& ray_org, const Vec3fa& ray_dir, const float ray_tnear, const float& ray_tfar,
                                        const LinearSpace3fa& ray_space, const float& depth_scale,
                                        const NativeCurve3ff& curve3D, const int N,
                                        const Epilog& epilog)
    {}
        
    template<template<typename Ty> class NativeCurve, int M = VSIZEX>
    struct RibbonCurve1Intersector1
    {};
    
    template<template<typename Ty> class NativeCurve, int K, int M = VSIZEX>
    struct RibbonCurve1IntersectorK
    {};
  }
}