summaryrefslogtreecommitdiff
path: root/tools/gfx/cpu/cpu-helper-functions.cpp
blob: 1aa9d82eb7794c8855e064da7c75ab92998cbcef (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
// cpu-helper-functions.cpp
#include "cpu-helper-functions.h"

#include "cpu-device.h"

namespace gfx
{
using namespace Slang;

Result SLANG_MCALL createCPUDevice(const IDevice::Desc* desc, IDevice** outDevice)
{
    RefPtr<cpu::DeviceImpl> result = new cpu::DeviceImpl();
    SLANG_RETURN_ON_FAIL(result->initialize(*desc));
    returnComPtr(outDevice, result);
    return SLANG_OK;
}

} // namespace gfx