1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49
|
// Copyright 2009 Intel Corporation
// SPDX-License-Identifier: Apache-2.0
#pragma once
#include "common/FeatureFlagsEnum.h"
#include "common/World.ih"
// c++ shared
#include "AORendererShared.h"
#include "common/RayCone.ih"
OSPRAY_BEGIN_ISPC_NAMESPACE
struct DifferentialGeometry;
struct FrameBuffer;
struct ScreenSample;
struct SurfaceShadingInfo
{
vec4f shadedColor;
vec3f albedo;
};
typedef SurfaceShadingInfo SSI;
inline void computeDG(const World *uniform world,
const AORenderer *uniform renderer,
const Ray &ray,
RayCone &rayCone,
DifferentialGeometry &dg,
const uniform FeatureFlagsHandler &ffh)
{
postIntersect(world,
&renderer->super,
dg,
ray,
rayCone,
DG_NG | DG_NS | DG_NORMALIZE | DG_FACEFORWARD | DG_COLOR | DG_TEXCOORD
| DG_TANGENTS,
ffh);
}
SYCL_EXTERNAL SSI AORenderer_computeShading(const AORenderer *uniform self,
const World *uniform world,
const DifferentialGeometry &dg,
ScreenSample &sample,
const uniform FeatureFlagsHandler &ffh);
OSPRAY_END_ISPC_NAMESPACE
|