DiCE API nvidia_logo_transpbg.gif Up
iallocator.h
Go to the documentation of this file.
1/***************************************************************************************************
2 * Copyright 2023 NVIDIA Corporation. All rights reserved.
3 **************************************************************************************************/
6
7#ifndef MI_NEURAYLIB_IALLOCATOR_H
8#define MI_NEURAYLIB_IALLOCATOR_H
9
10#include <mi/base/types.h>
12#include <mi/base/iallocator.h>
13
14namespace mi {
15
16namespace neuraylib {
17
29class IAllocator : public
30 mi::base::Interface_declare<0x952af060,0xe2a6,0x4bd7,0xa2,0x52,0x9f,0x6d,0x39,0xfb,0x50,0xa3,
31 base::IAllocator>
32{
33public:
58 virtual void* malloc(Size size) = 0;
59
67 virtual void free(void* memory) = 0;
68
77};
78 // end group mi_neuray_ineuray
80
81} // namespace neuraylib
82
83} // namespace mi
84
85#endif // MI_NEURAYLIB_IALLOCATOR_H
Allocator interface class to dynamically allocate and deallocate memory.
Mixin class template for deriving new interface declarations.
Definition: interface_declare.h:43
The Allocator interface class supports allocating and releasing memory dynamically and querying the a...
Definition: iallocator.h:32
virtual void * malloc(Size size)=0
Allocates a memory block of the given size.
virtual void free(void *memory)=0
Releases the given memory block.
virtual Size get_used_extra_memory()=0
This function is used by DiCE to inquire the amount of extra memory currently in use in the applicati...
Uint64 Size
Unsigned integral type that is large enough to hold the size of all types.
Definition: types.h:112
Mixin class template for deriving new interface declarations.
Common namespace for APIs of NVIDIA Advanced Rendering Center GmbH.
Definition: dice.h:89
Basic types.