NVIDIA OptiX 7.1 API nvidia_logo_transpbg.gif Up
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
optix_7_host.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2020 NVIDIA Corporation. All rights reserved.
3  *
4  * NVIDIA Corporation and its licensors retain all intellectual property and proprietary
5  * rights in and to this software, related documentation and any modifications thereto.
6  * Any use, reproduction, disclosure or distribution of this software and related
7  * documentation without an express license agreement from NVIDIA Corporation is strictly
8  * prohibited.
9  *
10  * TO THE MAXIMUM EXTENT PERMITTED BY APPLICABLE LAW, THIS SOFTWARE IS PROVIDED *AS IS*
11  * AND NVIDIA AND ITS SUPPLIERS DISCLAIM ALL WARRANTIES, EITHER EXPRESS OR IMPLIED,
12  * INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
13  * PARTICULAR PURPOSE. IN NO EVENT SHALL NVIDIA OR ITS SUPPLIERS BE LIABLE FOR ANY
14  * SPECIAL, INCIDENTAL, INDIRECT, OR CONSEQUENTIAL DAMAGES WHATSOEVER (INCLUDING, WITHOUT
15  * LIMITATION, DAMAGES FOR LOSS OF BUSINESS PROFITS, BUSINESS INTERRUPTION, LOSS OF
16  * BUSINESS INFORMATION, OR ANY OTHER PECUNIARY LOSS) ARISING OUT OF THE USE OF OR
17  * INABILITY TO USE THIS SOFTWARE, EVEN IF NVIDIA HAS BEEN ADVISED OF THE POSSIBILITY OF
18  * SUCH DAMAGES
19  */
20 
27 
28 #if !defined( __OPTIX_INCLUDE_INTERNAL_HEADERS__ )
29 #error("optix_7_host.h is an internal header file and must not be used directly. Please use optix_host.h or optix.h instead.")
30 #endif
31 
32 #ifndef __optix_optix_7_host_h__
33 #define __optix_optix_7_host_h__
34 
35 #include "optix_7_types.h"
36 #if !defined( OPTIX_DONT_INCLUDE_CUDA )
37 // If OPTIX_DONT_INCLUDE_CUDA is defined, cuda driver types must be defined through other
38 // means before including optix headers.
39 #include <cuda.h>
40 #endif
41 
42 #ifdef __cplusplus
43 extern "C" {
44 #endif
45 
48 
51 
52 
63 const char* optixGetErrorName( OptixResult result );
64 
75 const char* optixGetErrorString( OptixResult result );
76 
78 
81 
100 OptixResult optixDeviceContextCreate( CUcontext fromContext, const OptixDeviceContextOptions* options, OptixDeviceContext* context );
101 
111 
118 OptixResult optixDeviceContextGetProperty( OptixDeviceContext context, OptixDeviceProperty property, void* value, size_t sizeInBytes );
119 
134  OptixLogCallback callbackFunction,
135  void* callbackData,
136  unsigned int callbackLevel );
137 
150  int enabled );
151 
172 OptixResult optixDeviceContextSetCacheLocation( OptixDeviceContext context, const char* location );
173 
195 OptixResult optixDeviceContextSetCacheDatabaseSizes( OptixDeviceContext context, size_t lowWaterMark, size_t highWaterMark );
196 
207 OptixResult optixDeviceContextGetCacheLocation( OptixDeviceContext context, char* location, size_t locationSize );
208 
214 OptixResult optixDeviceContextGetCacheDatabaseSizes( OptixDeviceContext context, size_t* lowWaterMark, size_t* highWaterMark );
215 
217 
220 
245  const OptixPipelineCompileOptions* pipelineCompileOptions,
246  const OptixPipelineLinkOptions* pipelineLinkOptions,
247  const OptixProgramGroup* programGroups,
248  unsigned int numProgramGroups,
249  char* logString,
250  size_t* logStringSize,
251  OptixPipeline* pipeline );
252 
255 
279  unsigned int directCallableStackSizeFromTraversal,
280  unsigned int directCallableStackSizeFromState,
281  unsigned int continuationStackSize,
282  unsigned int maxTraversableGraphDepth );
283 
285 
288 
315  const OptixModuleCompileOptions* moduleCompileOptions,
316  const OptixPipelineCompileOptions* pipelineCompileOptions,
317  const char* PTX,
318  size_t PTXsize,
319  char* logString,
320  size_t* logStringSize,
321  OptixModule* module );
322 
329 
334  const OptixModuleCompileOptions* moduleCompileOptions,
335  const OptixPipelineCompileOptions* pipelineCompileOptions,
336  const OptixBuiltinISOptions* builtinISOptions,
337  OptixModule* builtinModule );
338 
340 
343 
349 
376  const OptixProgramGroupDesc* programDescriptions,
377  unsigned int numProgramGroups,
378  const OptixProgramGroupOptions* options,
379  char* logString,
380  size_t* logStringSize,
381  OptixProgramGroup* programGroups );
382 
385 
387 
390 
418  CUstream stream,
419  CUdeviceptr pipelineParams,
420  size_t pipelineParamsSize,
421  const OptixShaderBindingTable* sbt,
422  unsigned int width,
423  unsigned int height,
424  unsigned int depth );
425 
428 OptixResult optixSbtRecordPackHeader( OptixProgramGroup programGroup, void* sbtRecordHeaderHostPointer );
429 
431 
434 
441  const OptixAccelBuildOptions* accelOptions,
442  const OptixBuildInput* buildInputs,
443  unsigned int numBuildInputs,
444  OptixAccelBufferSizes* bufferSizes );
445 
459  CUstream stream,
460  const OptixAccelBuildOptions* accelOptions,
461  const OptixBuildInput* buildInputs,
462  unsigned int numBuildInputs,
463  CUdeviceptr tempBuffer,
464  size_t tempBufferSizeInBytes,
465  CUdeviceptr outputBuffer,
466  size_t outputBufferSizeInBytes,
467  OptixTraversableHandle* outputHandle,
468  const OptixAccelEmitDesc* emittedProperties,
469  unsigned int numEmittedProperties );
470 
489 
502 
537  CUstream stream,
538  const OptixAccelRelocationInfo* info,
539  CUdeviceptr instanceTraversableHandles,
540  size_t numInstanceTraversableHandles,
541  CUdeviceptr targetAccel,
542  size_t targetAccelSizeInBytes,
543  OptixTraversableHandle* targetHandle );
544 
563  CUstream stream,
564  OptixTraversableHandle inputHandle,
565  CUdeviceptr outputBuffer,
566  size_t outputBufferSizeInBytes,
567  OptixTraversableHandle* outputHandle );
568 
574  CUdeviceptr pointer,
575  OptixTraversableType traversableType,
576  OptixTraversableHandle* traversableHandle );
577 
579 
582 
589 
599 OptixResult optixDenoiserSetModel( OptixDenoiser denoiser, OptixDenoiserModelKind kind, void* data, size_t sizeInBytes );
600 
603 
622  unsigned int outputWidth,
623  unsigned int outputHeight,
624  OptixDenoiserSizes* returnSizes );
625 
643  CUstream stream,
644  unsigned int inputWidth,
645  unsigned int inputHeight,
646  CUdeviceptr denoiserState,
647  size_t denoiserStateSizeInBytes,
648  CUdeviceptr scratch,
649  size_t scratchSizeInBytes );
650 
677  CUstream stream,
678  const OptixDenoiserParams* params,
679  CUdeviceptr denoiserState,
680  size_t denoiserStateSizeInBytes,
681  const OptixImage2D* inputLayers,
682  unsigned int numInputLayers,
683  unsigned int inputOffsetX,
684  unsigned int inputOffsetY,
685  const OptixImage2D* outputLayer,
686  CUdeviceptr scratch,
687  size_t scratchSizeInBytes );
688 
713  CUstream stream,
714  const OptixImage2D* inputImage,
715  CUdeviceptr outputIntensity,
716  CUdeviceptr scratch,
717  size_t scratchSizeInBytes );
718 
720 
721 #ifdef __cplusplus
722 }
723 #endif
724 
725 #include "optix_function_table.h"
726 
727 #endif // __optix_optix_7_host_h__
728