mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-09-06 05:45:52 +00:00
Split 'linux' os-specific code into 'posix' and then 'linux'/'android'
* And eventually probably 'apple' as well.
This commit is contained in:
+7
-1
@@ -45,7 +45,13 @@ if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${warning_flags}")
|
||||
endif()
|
||||
|
||||
add_definitions(-DRENDERDOC_PLATFORM_LINUX)
|
||||
add_definitions(-DRENDERDOC_PLATFORM_POSIX)
|
||||
|
||||
if(ANDROID)
|
||||
add_definitions(-DRENDERDOC_PLATFORM_ANDROID)
|
||||
elseif(UNIX)
|
||||
add_definitions(-DRENDERDOC_PLATFORM_LINUX)
|
||||
endif()
|
||||
|
||||
add_subdirectory(renderdoc)
|
||||
|
||||
|
||||
@@ -58,7 +58,7 @@ win32 {
|
||||
QMAKE_CXXFLAGS += -std=c++11 -Wno-unused-parameter -Wno-reorder
|
||||
|
||||
QT += x11extras
|
||||
DEFINES += RENDERDOC_PLATFORM_LINUX
|
||||
DEFINES += RENDERDOC_PLATFORM_POSIX RENDERDOC_PLATFORM_LINUX
|
||||
}
|
||||
|
||||
SOURCES += Code/main.cpp \
|
||||
|
||||
+27
-11
@@ -126,20 +126,36 @@ set(sources
|
||||
3rdparty/tinyexr/tinyexr.cpp
|
||||
3rdparty/tinyexr/tinyexr.h)
|
||||
|
||||
if(UNIX)
|
||||
if(ANDROID)
|
||||
list(APPEND sources
|
||||
data/embedded_files.h
|
||||
os/linux/linux_callstack.cpp
|
||||
os/linux/linux_hook.cpp
|
||||
os/linux/linux_hook.h
|
||||
os/linux/linux_network.cpp
|
||||
os/linux/linux_process.cpp
|
||||
os/linux/linux_stringio.cpp
|
||||
os/linux/linux_threading.cpp
|
||||
os/linux/linux_specific.h)
|
||||
# linux_libentry must be the last so that library_loaded is called after
|
||||
os/posix/android/android_stringio.cpp
|
||||
os/posix/android/android_callstack.cpp
|
||||
os/posix/posix_hook.cpp
|
||||
os/posix/posix_hook.h
|
||||
os/posix/posix_network.cpp
|
||||
os/posix/posix_process.cpp
|
||||
os/posix/posix_stringio.cpp
|
||||
os/posix/posix_threading.cpp
|
||||
os/posix/posix_specific.h)
|
||||
# posix_libentry must be the last so that library_loaded is called after
|
||||
# static objects are constructed.
|
||||
list(APPEND sources os/linux/linux_libentry.cpp)
|
||||
list(APPEND sources os/posix/posix_libentry.cpp)
|
||||
elseif(UNIX)
|
||||
list(APPEND sources
|
||||
data/embedded_files.h
|
||||
os/posix/linux/linux_stringio.cpp
|
||||
os/posix/linux/linux_callstack.cpp
|
||||
os/posix/posix_hook.cpp
|
||||
os/posix/posix_hook.h
|
||||
os/posix/posix_network.cpp
|
||||
os/posix/posix_process.cpp
|
||||
os/posix/posix_stringio.cpp
|
||||
os/posix/posix_threading.cpp
|
||||
os/posix/posix_specific.h)
|
||||
# posix_libentry must be the last so that library_loaded is called after
|
||||
# static objects are constructed.
|
||||
list(APPEND sources os/posix/posix_libentry.cpp)
|
||||
endif()
|
||||
|
||||
if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
||||
|
||||
@@ -40,7 +40,7 @@ typedef uint32_t bool32;
|
||||
#endif
|
||||
#define RENDERDOC_CC __cdecl
|
||||
|
||||
#elif defined(RENDERDOC_PLATFORM_LINUX)
|
||||
#elif defined(RENDERDOC_PLATFORM_POSIX)
|
||||
|
||||
#ifdef RENDERDOC_EXPORTS
|
||||
#define RENDERDOC_API __attribute__ ((visibility ("default")))
|
||||
|
||||
@@ -47,7 +47,7 @@ struct GLWindowingData
|
||||
HWND wnd;
|
||||
};
|
||||
|
||||
#elif defined(RENDERDOC_PLATFORM_LINUX)
|
||||
#elif defined(RENDERDOC_PLATFORM_POSIX)
|
||||
// cheeky way to prevent GL/gl.h from being included, as we want to use
|
||||
// glcorearb.h from above
|
||||
#define __gl_h_
|
||||
|
||||
@@ -41,10 +41,10 @@ set(sources
|
||||
set(definitions ${RDOC_DEFINITIONS})
|
||||
|
||||
if(ANDROID)
|
||||
list(APPEND sources vk_linux.cpp)
|
||||
list(APPEND sources vk_posix.cpp vk_android.cpp)
|
||||
list(APPEND definitions PRIVATE -DVK_USE_PLATFORM_ANDROID_KHR)
|
||||
elseif(UNIX)
|
||||
list(APPEND sources vk_linux.cpp)
|
||||
list(APPEND sources vk_posix.cpp vk_linux.cpp)
|
||||
|
||||
list(APPEND definitions
|
||||
PRIVATE -DVK_USE_PLATFORM_XCB_KHR
|
||||
|
||||
@@ -32,9 +32,15 @@
|
||||
<ClCompile Include="vk_manager.cpp" />
|
||||
<ClCompile Include="vk_replay.cpp" />
|
||||
<ClCompile Include="vk_win32.cpp" />
|
||||
<ClCompile Include="vk_posix.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="vk_linux.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="vk_android.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="vk_resources.cpp" />
|
||||
<ClCompile Include="wrappers\vk_cmd_funcs.cpp" />
|
||||
<ClCompile Include="wrappers\vk_dynamic_funcs.cpp" />
|
||||
@@ -224,4 +230,4 @@
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
</Project>
|
||||
|
||||
@@ -4,9 +4,6 @@
|
||||
<ClCompile Include="vk_win32.cpp">
|
||||
<Filter>OS\Win32</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="vk_linux.cpp">
|
||||
<Filter>OS\Linux</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="vk_replay.cpp">
|
||||
<Filter>Replay</Filter>
|
||||
</ClCompile>
|
||||
@@ -82,6 +79,15 @@
|
||||
<ClCompile Include="vk_counters.cpp">
|
||||
<Filter>Replay</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="vk_android.cpp">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="vk_posix.cpp">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="vk_linux.cpp">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="vk_replay.h">
|
||||
@@ -128,9 +134,6 @@
|
||||
<Filter Include="OS">
|
||||
<UniqueIdentifier>{0ca21de2-97db-4118-afc5-32b4cd80a437}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="OS\Linux">
|
||||
<UniqueIdentifier>{c6141a90-0765-4409-afe2-e59d683e5a5e}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="OS\Win32">
|
||||
<UniqueIdentifier>{538183db-17ae-4e49-87d6-b8dc88bda2d3}</UniqueIdentifier>
|
||||
</Filter>
|
||||
@@ -152,6 +155,9 @@
|
||||
<Filter Include="official">
|
||||
<UniqueIdentifier>{9580e52e-f3ab-4ef9-80d1-c673e5f25ef7}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="OS\Posix">
|
||||
<UniqueIdentifier>{c6141a90-0765-4409-afe2-e59d683e5a5e}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="renderdoc.json">
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
******************************************************************************/
|
||||
|
||||
#include "vk_replay.h"
|
||||
#include "vk_core.h"
|
||||
|
||||
void VulkanReplay::OutputWindow::SetWindowHandle(void *wn)
|
||||
{
|
||||
wnd = (ANativeWindow*) wn;
|
||||
}
|
||||
|
||||
void VulkanReplay::OutputWindow::CreateSurface(VkInstance inst)
|
||||
{
|
||||
VkAndroidSurfaceCreateInfoKHR createInfo;
|
||||
|
||||
createInfo.sType = VK_STRUCTURE_TYPE_ANDROID_SURFACE_CREATE_INFO_KHR;
|
||||
createInfo.pNext = NULL;
|
||||
createInfo.flags = 0;
|
||||
createInfo.window = wnd;
|
||||
|
||||
VkResult vkr = ObjDisp(inst)->CreateAndroidSurfaceKHR(Unwrap(inst), &createInfo, NULL, &surface);
|
||||
RDCASSERTEQUAL(vkr, VK_SUCCESS);
|
||||
}
|
||||
|
||||
void VulkanReplay::GetOutputWindowDimensions(uint64_t id, int32_t &w, int32_t &h)
|
||||
{
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2015-2016 Baldur Karlsson
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@@ -25,17 +25,8 @@
|
||||
#include "vk_replay.h"
|
||||
#include "vk_core.h"
|
||||
|
||||
struct xcb_connection_t;
|
||||
namespace Keyboard
|
||||
{
|
||||
void UseConnection(xcb_connection_t *conn);
|
||||
}
|
||||
|
||||
void VulkanReplay::OutputWindow::SetWindowHandle(void *wn)
|
||||
{
|
||||
#ifdef ANDROID
|
||||
wnd = (ANativeWindow*) wn;
|
||||
#else
|
||||
void **connectionScreenWindow = (void **)wn;
|
||||
|
||||
connection = (xcb_connection_t *)connectionScreenWindow[0];
|
||||
@@ -47,22 +38,10 @@ void VulkanReplay::OutputWindow::SetWindowHandle(void *wn)
|
||||
while (scr-- > 0) xcb_screen_next(&iter);
|
||||
|
||||
screen = iter.data;
|
||||
#endif
|
||||
}
|
||||
|
||||
void VulkanReplay::OutputWindow::CreateSurface(VkInstance inst)
|
||||
{
|
||||
#ifdef ANDROID
|
||||
VkAndroidSurfaceCreateInfoKHR createInfo;
|
||||
|
||||
createInfo.sType = VK_STRUCTURE_TYPE_ANDROID_SURFACE_CREATE_INFO_KHR;
|
||||
createInfo.pNext = NULL;
|
||||
createInfo.flags = 0;
|
||||
createInfo.window = wnd;
|
||||
|
||||
VkResult vkr = ObjDisp(inst)->CreateAndroidSurfaceKHR(Unwrap(inst), &createInfo, NULL, &surface);
|
||||
RDCASSERTEQUAL(vkr, VK_SUCCESS);
|
||||
#else
|
||||
VkXcbSurfaceCreateInfoKHR createInfo;
|
||||
|
||||
createInfo.sType = VK_STRUCTURE_TYPE_XCB_SURFACE_CREATE_INFO_KHR;
|
||||
@@ -73,13 +52,10 @@ void VulkanReplay::OutputWindow::CreateSurface(VkInstance inst)
|
||||
|
||||
VkResult vkr = ObjDisp(inst)->CreateXcbSurfaceKHR(Unwrap(inst), &createInfo, NULL, &surface);
|
||||
RDCASSERTEQUAL(vkr, VK_SUCCESS);
|
||||
#endif
|
||||
}
|
||||
|
||||
void VulkanReplay::GetOutputWindowDimensions(uint64_t id, int32_t &w, int32_t &h)
|
||||
{
|
||||
#ifdef ANDROID
|
||||
#else
|
||||
if(id == 0 || m_OutputWindows.find(id) == m_OutputWindows.end())
|
||||
return;
|
||||
|
||||
@@ -92,149 +68,4 @@ void VulkanReplay::GetOutputWindowDimensions(uint64_t id, int32_t &w, int32_t &h
|
||||
h = (int32_t)geom->height;
|
||||
|
||||
free(geom);
|
||||
#endif
|
||||
}
|
||||
|
||||
bool VulkanReplay::IsOutputWindowVisible(uint64_t id)
|
||||
{
|
||||
if(id == 0 || m_OutputWindows.find(id) == m_OutputWindows.end())
|
||||
return false;
|
||||
|
||||
VULKANNOTIMP("Optimisation missing - output window always returning true");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void WrappedVulkan::AddRequiredExtensions(bool instance, vector<string> &extensionList)
|
||||
{
|
||||
bool device = !instance;
|
||||
|
||||
// TODO should check if these are present..
|
||||
|
||||
if(instance)
|
||||
{
|
||||
extensionList.push_back(VK_KHR_SURFACE_EXTENSION_NAME);
|
||||
|
||||
#if defined(VK_USE_PLATFORM_XCB_KHR)
|
||||
extensionList.push_back(VK_KHR_XCB_SURFACE_EXTENSION_NAME);
|
||||
#endif
|
||||
|
||||
#if defined(VK_USE_PLATFORM_XLIB_KHR)
|
||||
extensionList.push_back(VK_KHR_XLIB_SURFACE_EXTENSION_NAME);
|
||||
#endif
|
||||
}
|
||||
else if(device)
|
||||
{
|
||||
extensionList.push_back(VK_KHR_SWAPCHAIN_EXTENSION_NAME);
|
||||
}
|
||||
}
|
||||
|
||||
#if defined(VK_USE_PLATFORM_XCB_KHR)
|
||||
|
||||
VkBool32 WrappedVulkan::vkGetPhysicalDeviceXcbPresentationSupportKHR(
|
||||
VkPhysicalDevice physicalDevice,
|
||||
uint32_t queueFamilyIndex,
|
||||
xcb_connection_t* connection,
|
||||
xcb_visualid_t visual_id)
|
||||
{
|
||||
return ObjDisp(physicalDevice)->GetPhysicalDeviceXcbPresentationSupportKHR(Unwrap(physicalDevice), queueFamilyIndex, connection, visual_id);
|
||||
}
|
||||
|
||||
VkResult WrappedVulkan::vkCreateXcbSurfaceKHR(
|
||||
VkInstance instance,
|
||||
const VkXcbSurfaceCreateInfoKHR* pCreateInfo,
|
||||
const VkAllocationCallbacks* pAllocator,
|
||||
VkSurfaceKHR* pSurface)
|
||||
{
|
||||
// should not come in here at all on replay
|
||||
RDCASSERT(m_State >= WRITING);
|
||||
|
||||
VkResult ret = ObjDisp(instance)->CreateXcbSurfaceKHR(Unwrap(instance), pCreateInfo, pAllocator, pSurface);
|
||||
|
||||
if(ret == VK_SUCCESS)
|
||||
{
|
||||
GetResourceManager()->WrapResource(Unwrap(instance), *pSurface);
|
||||
|
||||
WrappedVkSurfaceKHR *wrapped = GetWrapped(*pSurface);
|
||||
|
||||
// since there's no point in allocating a full resource record and storing the window
|
||||
// handle under there somewhere, we just cast. We won't use the resource record for anything
|
||||
wrapped->record = (VkResourceRecord *)(uintptr_t)pCreateInfo->window;
|
||||
|
||||
Keyboard::UseConnection(pCreateInfo->connection);
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
#if defined(VK_USE_PLATFORM_XLIB_KHR)
|
||||
|
||||
VkBool32 WrappedVulkan::vkGetPhysicalDeviceXlibPresentationSupportKHR(
|
||||
VkPhysicalDevice physicalDevice,
|
||||
uint32_t queueFamilyIndex,
|
||||
Display* dpy,
|
||||
VisualID visualID)
|
||||
{
|
||||
return ObjDisp(physicalDevice)->GetPhysicalDeviceXlibPresentationSupportKHR(Unwrap(physicalDevice), queueFamilyIndex, dpy, visualID);
|
||||
}
|
||||
|
||||
VkResult WrappedVulkan::vkCreateXlibSurfaceKHR(
|
||||
VkInstance instance,
|
||||
const VkXlibSurfaceCreateInfoKHR* pCreateInfo,
|
||||
const VkAllocationCallbacks* pAllocator,
|
||||
VkSurfaceKHR* pSurface)
|
||||
{
|
||||
// should not come in here at all on replay
|
||||
RDCASSERT(m_State >= WRITING);
|
||||
|
||||
VkResult ret = ObjDisp(instance)->CreateXlibSurfaceKHR(Unwrap(instance), pCreateInfo, pAllocator, pSurface);
|
||||
|
||||
if(ret == VK_SUCCESS)
|
||||
{
|
||||
GetResourceManager()->WrapResource(Unwrap(instance), *pSurface);
|
||||
|
||||
WrappedVkSurfaceKHR *wrapped = GetWrapped(*pSurface);
|
||||
|
||||
// since there's no point in allocating a full resource record and storing the window
|
||||
// handle under there somewhere, we just cast. We won't use the resource record for anything
|
||||
wrapped->record = (VkResourceRecord *)pCreateInfo->window;
|
||||
|
||||
// VKTODOLOW Should support Xlib here
|
||||
//Keyboard::UseConnection(pCreateInfo->dpy);
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
#if defined(VK_USE_PLATFORM_ANDROID_KHR)
|
||||
VkResult WrappedVulkan::vkCreateAndroidSurfaceKHR(
|
||||
VkInstance instance,
|
||||
const VkAndroidSurfaceCreateInfoKHR* pCreateInfo,
|
||||
const VkAllocationCallbacks* pAllocator,
|
||||
VkSurfaceKHR* pSurface)
|
||||
{
|
||||
// should not come in here at all on replay
|
||||
RDCASSERT(m_State >= WRITING);
|
||||
|
||||
VkResult ret = ObjDisp(instance)->CreateAndroidSurfaceKHR(Unwrap(instance), pCreateInfo, pAllocator, pSurface);
|
||||
|
||||
if(ret == VK_SUCCESS)
|
||||
{
|
||||
GetResourceManager()->WrapResource(Unwrap(instance), *pSurface);
|
||||
|
||||
WrappedVkSurfaceKHR *wrapped = GetWrapped(*pSurface);
|
||||
|
||||
// since there's no point in allocating a full resource record and storing the window
|
||||
// handle under there somewhere, we just cast. We won't use the resource record for anything
|
||||
wrapped->record = (VkResourceRecord *)(uintptr_t)pCreateInfo->window;
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
#endif
|
||||
|
||||
const char *VulkanLibraryName = "libvulkan.so";
|
||||
|
||||
@@ -0,0 +1,176 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
******************************************************************************/
|
||||
|
||||
#include "vk_replay.h"
|
||||
#include "vk_core.h"
|
||||
|
||||
bool VulkanReplay::IsOutputWindowVisible(uint64_t id)
|
||||
{
|
||||
if(id == 0 || m_OutputWindows.find(id) == m_OutputWindows.end())
|
||||
return false;
|
||||
|
||||
VULKANNOTIMP("Optimisation missing - output window always returning true");
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void WrappedVulkan::AddRequiredExtensions(bool instance, vector<string> &extensionList)
|
||||
{
|
||||
bool device = !instance;
|
||||
|
||||
// TODO should check if these are present..
|
||||
|
||||
if(instance)
|
||||
{
|
||||
extensionList.push_back(VK_KHR_SURFACE_EXTENSION_NAME);
|
||||
|
||||
#if defined(VK_USE_PLATFORM_XCB_KHR)
|
||||
extensionList.push_back(VK_KHR_XCB_SURFACE_EXTENSION_NAME);
|
||||
#endif
|
||||
|
||||
#if defined(VK_USE_PLATFORM_XLIB_KHR)
|
||||
extensionList.push_back(VK_KHR_XLIB_SURFACE_EXTENSION_NAME);
|
||||
#endif
|
||||
}
|
||||
else if(device)
|
||||
{
|
||||
extensionList.push_back(VK_KHR_SWAPCHAIN_EXTENSION_NAME);
|
||||
}
|
||||
}
|
||||
|
||||
#if defined(VK_USE_PLATFORM_XCB_KHR)
|
||||
|
||||
VkBool32 WrappedVulkan::vkGetPhysicalDeviceXcbPresentationSupportKHR(
|
||||
VkPhysicalDevice physicalDevice,
|
||||
uint32_t queueFamilyIndex,
|
||||
xcb_connection_t* connection,
|
||||
xcb_visualid_t visual_id)
|
||||
{
|
||||
return ObjDisp(physicalDevice)->GetPhysicalDeviceXcbPresentationSupportKHR(Unwrap(physicalDevice), queueFamilyIndex, connection, visual_id);
|
||||
}
|
||||
|
||||
struct xcb_connection_t;
|
||||
namespace Keyboard
|
||||
{
|
||||
void UseConnection(xcb_connection_t *conn);
|
||||
}
|
||||
|
||||
VkResult WrappedVulkan::vkCreateXcbSurfaceKHR(
|
||||
VkInstance instance,
|
||||
const VkXcbSurfaceCreateInfoKHR* pCreateInfo,
|
||||
const VkAllocationCallbacks* pAllocator,
|
||||
VkSurfaceKHR* pSurface)
|
||||
{
|
||||
// should not come in here at all on replay
|
||||
RDCASSERT(m_State >= WRITING);
|
||||
|
||||
VkResult ret = ObjDisp(instance)->CreateXcbSurfaceKHR(Unwrap(instance), pCreateInfo, pAllocator, pSurface);
|
||||
|
||||
if(ret == VK_SUCCESS)
|
||||
{
|
||||
GetResourceManager()->WrapResource(Unwrap(instance), *pSurface);
|
||||
|
||||
WrappedVkSurfaceKHR *wrapped = GetWrapped(*pSurface);
|
||||
|
||||
// since there's no point in allocating a full resource record and storing the window
|
||||
// handle under there somewhere, we just cast. We won't use the resource record for anything
|
||||
wrapped->record = (VkResourceRecord *)(uintptr_t)pCreateInfo->window;
|
||||
|
||||
Keyboard::UseConnection(pCreateInfo->connection);
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
#if defined(VK_USE_PLATFORM_XLIB_KHR)
|
||||
|
||||
VkBool32 WrappedVulkan::vkGetPhysicalDeviceXlibPresentationSupportKHR(
|
||||
VkPhysicalDevice physicalDevice,
|
||||
uint32_t queueFamilyIndex,
|
||||
Display* dpy,
|
||||
VisualID visualID)
|
||||
{
|
||||
return ObjDisp(physicalDevice)->GetPhysicalDeviceXlibPresentationSupportKHR(Unwrap(physicalDevice), queueFamilyIndex, dpy, visualID);
|
||||
}
|
||||
|
||||
VkResult WrappedVulkan::vkCreateXlibSurfaceKHR(
|
||||
VkInstance instance,
|
||||
const VkXlibSurfaceCreateInfoKHR* pCreateInfo,
|
||||
const VkAllocationCallbacks* pAllocator,
|
||||
VkSurfaceKHR* pSurface)
|
||||
{
|
||||
// should not come in here at all on replay
|
||||
RDCASSERT(m_State >= WRITING);
|
||||
|
||||
VkResult ret = ObjDisp(instance)->CreateXlibSurfaceKHR(Unwrap(instance), pCreateInfo, pAllocator, pSurface);
|
||||
|
||||
if(ret == VK_SUCCESS)
|
||||
{
|
||||
GetResourceManager()->WrapResource(Unwrap(instance), *pSurface);
|
||||
|
||||
WrappedVkSurfaceKHR *wrapped = GetWrapped(*pSurface);
|
||||
|
||||
// since there's no point in allocating a full resource record and storing the window
|
||||
// handle under there somewhere, we just cast. We won't use the resource record for anything
|
||||
wrapped->record = (VkResourceRecord *)pCreateInfo->window;
|
||||
|
||||
// VKTODOLOW Should support Xlib here
|
||||
//Keyboard::UseConnection(pCreateInfo->dpy);
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
#if defined(VK_USE_PLATFORM_ANDROID_KHR)
|
||||
VkResult WrappedVulkan::vkCreateAndroidSurfaceKHR(
|
||||
VkInstance instance,
|
||||
const VkAndroidSurfaceCreateInfoKHR* pCreateInfo,
|
||||
const VkAllocationCallbacks* pAllocator,
|
||||
VkSurfaceKHR* pSurface)
|
||||
{
|
||||
// should not come in here at all on replay
|
||||
RDCASSERT(m_State >= WRITING);
|
||||
|
||||
VkResult ret = ObjDisp(instance)->CreateAndroidSurfaceKHR(Unwrap(instance), pCreateInfo, pAllocator, pSurface);
|
||||
|
||||
if(ret == VK_SUCCESS)
|
||||
{
|
||||
GetResourceManager()->WrapResource(Unwrap(instance), *pSurface);
|
||||
|
||||
WrappedVkSurfaceKHR *wrapped = GetWrapped(*pSurface);
|
||||
|
||||
// since there's no point in allocating a full resource record and storing the window
|
||||
// handle under there somewhere, we just cast. We won't use the resource record for anything
|
||||
wrapped->record = (VkResourceRecord *)(uintptr_t)pCreateInfo->window;
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
#endif
|
||||
|
||||
const char *VulkanLibraryName = "libvulkan.so";
|
||||
@@ -36,7 +36,7 @@
|
||||
#define WINDOW_HANDLE_DECL HWND wnd;
|
||||
#define NULL_WND_HANDLE NULL
|
||||
|
||||
#elif defined(ANDROID)
|
||||
#elif defined(RENDERDOC_PLATFORM_ANDROID)
|
||||
|
||||
#define WINDOW_HANDLE_DECL ANativeWindow *wnd;
|
||||
#define NULL_WND_HANDLE NULL
|
||||
|
||||
@@ -75,9 +75,9 @@ class Hook
|
||||
#define HOOKS_END() Win32_IAT_EndHooks()
|
||||
#define HOOKS_REMOVE() Win32_IAT_RemoveHooks()
|
||||
|
||||
#elif defined(LINUX)
|
||||
#elif defined(RENDERDOC_PLATFORM_POSIX)
|
||||
|
||||
#include "os/linux/linux_hook.h"
|
||||
#include "os/posix/posix_hook.h"
|
||||
|
||||
// just need this for dlsym
|
||||
#include <dlfcn.h>
|
||||
|
||||
@@ -330,8 +330,8 @@ namespace Bits
|
||||
|
||||
#if defined(RENDERDOC_PLATFORM_WIN32)
|
||||
#include "win32/win32_specific.h"
|
||||
#elif defined(RENDERDOC_PLATFORM_LINUX)
|
||||
#include "linux/linux_specific.h"
|
||||
#elif defined(RENDERDOC_PLATFORM_POSIX)
|
||||
#include "posix/posix_specific.h"
|
||||
#else
|
||||
#error Undefined Platform!
|
||||
#endif
|
||||
|
||||
@@ -0,0 +1,106 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
******************************************************************************/
|
||||
|
||||
#include "os/os_specific.h"
|
||||
|
||||
class AndroidCallstack : public Callstack::Stackwalk
|
||||
{
|
||||
public:
|
||||
AndroidCallstack()
|
||||
{
|
||||
RDCEraseEl(addrs);
|
||||
numLevels = 0;
|
||||
}
|
||||
AndroidCallstack(uint64_t *calls, size_t num)
|
||||
{
|
||||
Set(calls, num);
|
||||
}
|
||||
~AndroidCallstack() {}
|
||||
|
||||
void Set(uint64_t *calls, size_t num)
|
||||
{
|
||||
numLevels = num;
|
||||
for(int i=0; i < numLevels; i++)
|
||||
addrs[i] = calls[i];
|
||||
}
|
||||
|
||||
size_t NumLevels() const { return 0; }
|
||||
const uint64_t *GetAddrs() const { return addrs; }
|
||||
private:
|
||||
AndroidCallstack(const Callstack::Stackwalk &other);
|
||||
|
||||
uint64_t addrs[128];
|
||||
int numLevels;
|
||||
};
|
||||
|
||||
namespace Callstack
|
||||
{
|
||||
void Init()
|
||||
{
|
||||
}
|
||||
|
||||
Stackwalk *Collect()
|
||||
{
|
||||
return new AndroidCallstack();
|
||||
}
|
||||
|
||||
Stackwalk *Create()
|
||||
{
|
||||
return new AndroidCallstack(NULL, 0);
|
||||
}
|
||||
|
||||
bool GetLoadedModules(char *&buf, size_t &size)
|
||||
{
|
||||
if(buf)
|
||||
{
|
||||
buf[0] = 'A';
|
||||
buf[1] = 'N';
|
||||
buf[2] = 'R';
|
||||
buf[3] = 'D';
|
||||
buf[4] = 'C';
|
||||
buf[5] = 'A';
|
||||
buf[6] = 'L';
|
||||
buf[7] = 'L';
|
||||
}
|
||||
|
||||
size += 8;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
class AndroidResolver : public Callstack::StackResolver
|
||||
{
|
||||
public:
|
||||
Callstack::AddressDetails GetAddr(uint64_t addr)
|
||||
{
|
||||
return Callstack::AddressDetails();
|
||||
}
|
||||
};
|
||||
|
||||
StackResolver *MakeResolver(char *moduleDB, size_t DBSize, string pdbSearchPaths, volatile bool *killSignal)
|
||||
{
|
||||
RDCERR("Callstack resolving not supported on Android.");
|
||||
return new AndroidResolver();
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,67 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
******************************************************************************/
|
||||
|
||||
#include "os/os_specific.h"
|
||||
|
||||
typedef int Display;
|
||||
|
||||
namespace Keyboard
|
||||
{
|
||||
void Init()
|
||||
{
|
||||
}
|
||||
|
||||
void CloneDisplay(Display *dpy) {}
|
||||
|
||||
void AddInputWindow(void *wnd)
|
||||
{
|
||||
}
|
||||
|
||||
void RemoveInputWindow(void *wnd)
|
||||
{
|
||||
}
|
||||
|
||||
bool GetKeyState(int key)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
namespace FileIO
|
||||
{
|
||||
const char *GetTempRootPath()
|
||||
{
|
||||
return "/sdcard";
|
||||
}
|
||||
};
|
||||
|
||||
namespace StringFormat
|
||||
{
|
||||
string Wide2UTF8(const std::wstring &s)
|
||||
{
|
||||
RDCFATAL("Converting wide strings to UTF-8 is not supported on Android!");
|
||||
return "";
|
||||
}
|
||||
};
|
||||
|
||||
+1
-9
@@ -1,8 +1,7 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2015-2016 Baldur Karlsson
|
||||
* Copyright (c) 2014 Crytek
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@@ -25,10 +24,7 @@
|
||||
|
||||
#include "os/os_specific.h"
|
||||
|
||||
#ifdef ANDROID
|
||||
#else
|
||||
#include <execinfo.h>
|
||||
#endif
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
|
||||
@@ -69,11 +65,7 @@ class LinuxCallstack : public Callstack::Stackwalk
|
||||
{
|
||||
void *addrs_ptr[ARRAY_COUNT(addrs)];
|
||||
|
||||
#ifdef ANDROID
|
||||
numLevels = 0;
|
||||
#else
|
||||
numLevels = backtrace(addrs_ptr, ARRAY_COUNT(addrs));
|
||||
#endif
|
||||
|
||||
int offs = 0;
|
||||
// if we want to trim levels of the stack, we can do that here
|
||||
@@ -0,0 +1,209 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
******************************************************************************/
|
||||
|
||||
|
||||
#include "os/os_specific.h"
|
||||
#include "api/app/renderdoc_app.h"
|
||||
|
||||
#include <time.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <errno.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
#include <pwd.h>
|
||||
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/keysym.h>
|
||||
|
||||
#include <xcb/xcb_keysyms.h>
|
||||
|
||||
#include <iconv.h>
|
||||
|
||||
#include "serialise/string_utils.h"
|
||||
#include "common/threading.h"
|
||||
using std::string;
|
||||
|
||||
namespace Keyboard
|
||||
{
|
||||
void Init()
|
||||
{
|
||||
}
|
||||
|
||||
xcb_connection_t *connection;
|
||||
xcb_key_symbols_t *symbols;
|
||||
|
||||
void CloneDisplay(Display *dpy) {}
|
||||
|
||||
void UseConnection(xcb_connection_t *conn)
|
||||
{
|
||||
connection = conn;
|
||||
symbols = xcb_key_symbols_alloc(conn);
|
||||
}
|
||||
|
||||
void AddInputWindow(void *wnd)
|
||||
{
|
||||
// TODO check against this drawable & parent window being focused in GetKeyState
|
||||
}
|
||||
|
||||
void RemoveInputWindow(void *wnd)
|
||||
{
|
||||
}
|
||||
|
||||
bool GetKeyState(int key)
|
||||
{
|
||||
KeySym ks = 0;
|
||||
|
||||
if(symbols == NULL) return false;
|
||||
|
||||
if(key >= eRENDERDOC_Key_A && key <= eRENDERDOC_Key_Z) ks = key;
|
||||
if(key >= eRENDERDOC_Key_0 && key <= eRENDERDOC_Key_9) ks = key;
|
||||
|
||||
switch(key)
|
||||
{
|
||||
case eRENDERDOC_Key_Divide: ks = XK_KP_Divide; break;
|
||||
case eRENDERDOC_Key_Multiply: ks = XK_KP_Multiply; break;
|
||||
case eRENDERDOC_Key_Subtract: ks = XK_KP_Subtract; break;
|
||||
case eRENDERDOC_Key_Plus: ks = XK_KP_Add; break;
|
||||
case eRENDERDOC_Key_F1: ks = XK_F1; break;
|
||||
case eRENDERDOC_Key_F2: ks = XK_F2; break;
|
||||
case eRENDERDOC_Key_F3: ks = XK_F3; break;
|
||||
case eRENDERDOC_Key_F4: ks = XK_F4; break;
|
||||
case eRENDERDOC_Key_F5: ks = XK_F5; break;
|
||||
case eRENDERDOC_Key_F6: ks = XK_F6; break;
|
||||
case eRENDERDOC_Key_F7: ks = XK_F7; break;
|
||||
case eRENDERDOC_Key_F8: ks = XK_F8; break;
|
||||
case eRENDERDOC_Key_F9: ks = XK_F9; break;
|
||||
case eRENDERDOC_Key_F10: ks = XK_F10; break;
|
||||
case eRENDERDOC_Key_F11: ks = XK_F11; break;
|
||||
case eRENDERDOC_Key_F12: ks = XK_F12; break;
|
||||
case eRENDERDOC_Key_Home: ks = XK_Home; break;
|
||||
case eRENDERDOC_Key_End: ks = XK_End; break;
|
||||
case eRENDERDOC_Key_Insert: ks = XK_Insert; break;
|
||||
case eRENDERDOC_Key_Delete: ks = XK_Delete; break;
|
||||
case eRENDERDOC_Key_PageUp: ks = XK_Prior; break;
|
||||
case eRENDERDOC_Key_PageDn: ks = XK_Next; break;
|
||||
case eRENDERDOC_Key_Backspace: ks = XK_BackSpace; break;
|
||||
case eRENDERDOC_Key_Tab: ks = XK_Tab; break;
|
||||
case eRENDERDOC_Key_PrtScrn: ks = XK_Print; break;
|
||||
case eRENDERDOC_Key_Pause: ks = XK_Pause; break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if(ks == 0)
|
||||
return false;
|
||||
|
||||
xcb_keycode_t *keyCodes = xcb_key_symbols_get_keycode(symbols, ks);
|
||||
|
||||
if(!keyCodes)
|
||||
return false;
|
||||
|
||||
xcb_query_keymap_cookie_t keymapcookie = xcb_query_keymap(connection);
|
||||
xcb_query_keymap_reply_t *keys = xcb_query_keymap_reply(connection, keymapcookie, NULL);
|
||||
|
||||
bool ret = false;
|
||||
|
||||
if(keys && keyCodes[0] != XCB_NO_SYMBOL)
|
||||
{
|
||||
int byteIdx = (keyCodes[0]/8);
|
||||
int bitMask = 1 << (keyCodes[0]%8);
|
||||
|
||||
ret = (keys->keys[byteIdx] & bitMask) != 0;
|
||||
}
|
||||
|
||||
free(keyCodes);
|
||||
free(keys);
|
||||
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
namespace FileIO
|
||||
{
|
||||
const char *GetTempRootPath()
|
||||
{
|
||||
return "/tmp";
|
||||
}
|
||||
};
|
||||
|
||||
namespace StringFormat
|
||||
{
|
||||
// cache iconv_t descriptor to save on iconv_open/iconv_close each time
|
||||
iconv_t iconvWide2UTF8 = (iconv_t)-1;
|
||||
|
||||
// iconv is not thread safe when sharing an iconv_t descriptor
|
||||
// I don't expect much contention but if it happens we could TryLock
|
||||
// before creating a temporary iconv_t, or hold two iconv_ts, or something.
|
||||
Threading::CriticalSection lockWide2UTF8;
|
||||
|
||||
string Wide2UTF8(const std::wstring &s)
|
||||
{
|
||||
// include room for null terminator, assuming unicode input (not ucs)
|
||||
// utf-8 characters can be max 4 bytes.
|
||||
size_t len = (s.length()+1)*4;
|
||||
|
||||
vector<char> charBuffer;
|
||||
|
||||
if(charBuffer.size() < len)
|
||||
charBuffer.resize(len);
|
||||
|
||||
size_t ret;
|
||||
|
||||
{
|
||||
SCOPED_LOCK(lockWide2UTF8);
|
||||
|
||||
if(iconvWide2UTF8 == (iconv_t)-1)
|
||||
iconvWide2UTF8 = iconv_open("UTF-8", "WCHAR_T");
|
||||
|
||||
if(iconvWide2UTF8 == (iconv_t)-1)
|
||||
{
|
||||
RDCERR("Couldn't open iconv for WCHAR_T to UTF-8: %d", errno);
|
||||
return "";
|
||||
}
|
||||
|
||||
char *inbuf = (char *)s.c_str();
|
||||
size_t insize = (s.length()+1)*sizeof(wchar_t); // include null terminator
|
||||
char *outbuf = &charBuffer[0];
|
||||
size_t outsize = len;
|
||||
|
||||
ret = iconv(iconvWide2UTF8, &inbuf, &insize, &outbuf, &outsize);
|
||||
}
|
||||
|
||||
if(ret == (size_t)-1)
|
||||
{
|
||||
#if !defined(_RELEASE)
|
||||
RDCWARN("Failed to convert wstring");
|
||||
#endif
|
||||
return "";
|
||||
}
|
||||
|
||||
// convert to string from null-terminated string - utf-8 never contains
|
||||
// 0 bytes before the null terminator, and this way we don't care if
|
||||
// charBuffer is larger than the string
|
||||
return string(&charBuffer[0]);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2015-2016 Baldur Karlsson
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@@ -24,7 +24,7 @@
|
||||
|
||||
#include "os/os_specific.h"
|
||||
|
||||
#include "linux_hook.h"
|
||||
#include "posix_hook.h"
|
||||
|
||||
#include "serialise/string_utils.h"
|
||||
#include "common/threading.h"
|
||||
@@ -1,7 +1,7 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2015-2016 Baldur Karlsson
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@@ -1,8 +1,7 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2015-2016 Baldur Karlsson
|
||||
* Copyright (c) 2014 Crytek
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@@ -1,8 +1,7 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2015-2016 Baldur Karlsson
|
||||
* Copyright (c) 2014 Crytek
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@@ -1,8 +1,7 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2015-2016 Baldur Karlsson
|
||||
* Copyright (c) 2014 Crytek
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@@ -1,8 +1,7 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2015-2016 Baldur Karlsson
|
||||
* Copyright (c) 2014 Crytek
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@@ -1,8 +1,7 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2015-2016 Baldur Karlsson
|
||||
* Copyright (c) 2014 Crytek
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@@ -36,22 +35,6 @@
|
||||
#include <unistd.h>
|
||||
#include <pwd.h>
|
||||
|
||||
#ifdef ANDROID
|
||||
typedef int Display;
|
||||
typedef int xcb_connection_t;
|
||||
typedef int xcb_key_symbols_t;
|
||||
typedef int KeySym;
|
||||
typedef int xcb_keycode_t;
|
||||
typedef int *iconv_t;
|
||||
#else
|
||||
#include <X11/Xlib.h>
|
||||
#include <X11/keysym.h>
|
||||
|
||||
#include <xcb/xcb_keysyms.h>
|
||||
|
||||
#include <iconv.h>
|
||||
#endif
|
||||
|
||||
// for dladdr
|
||||
#include <dlfcn.h>
|
||||
|
||||
@@ -62,111 +45,11 @@ using std::string;
|
||||
// gives us an address to identify this so with
|
||||
static int soLocator=0;
|
||||
|
||||
namespace Keyboard
|
||||
{
|
||||
void Init()
|
||||
{
|
||||
}
|
||||
|
||||
xcb_connection_t *connection;
|
||||
xcb_key_symbols_t *symbols;
|
||||
|
||||
void CloneDisplay(Display *dpy) {}
|
||||
|
||||
void UseConnection(xcb_connection_t *conn)
|
||||
{
|
||||
connection = conn;
|
||||
#ifdef ANDROID
|
||||
symbols = NULL;
|
||||
#else
|
||||
symbols = xcb_key_symbols_alloc(conn);
|
||||
#endif
|
||||
}
|
||||
|
||||
void AddInputWindow(void *wnd)
|
||||
{
|
||||
// TODO check against this drawable & parent window being focused in GetKeyState
|
||||
}
|
||||
|
||||
void RemoveInputWindow(void *wnd)
|
||||
{
|
||||
}
|
||||
|
||||
bool GetKeyState(int key)
|
||||
{
|
||||
#ifdef ANDROID
|
||||
return false;
|
||||
#else
|
||||
KeySym ks = 0;
|
||||
|
||||
if(symbols == NULL) return false;
|
||||
|
||||
if(key >= eRENDERDOC_Key_A && key <= eRENDERDOC_Key_Z) ks = key;
|
||||
if(key >= eRENDERDOC_Key_0 && key <= eRENDERDOC_Key_9) ks = key;
|
||||
|
||||
switch(key)
|
||||
{
|
||||
case eRENDERDOC_Key_Divide: ks = XK_KP_Divide; break;
|
||||
case eRENDERDOC_Key_Multiply: ks = XK_KP_Multiply; break;
|
||||
case eRENDERDOC_Key_Subtract: ks = XK_KP_Subtract; break;
|
||||
case eRENDERDOC_Key_Plus: ks = XK_KP_Add; break;
|
||||
case eRENDERDOC_Key_F1: ks = XK_F1; break;
|
||||
case eRENDERDOC_Key_F2: ks = XK_F2; break;
|
||||
case eRENDERDOC_Key_F3: ks = XK_F3; break;
|
||||
case eRENDERDOC_Key_F4: ks = XK_F4; break;
|
||||
case eRENDERDOC_Key_F5: ks = XK_F5; break;
|
||||
case eRENDERDOC_Key_F6: ks = XK_F6; break;
|
||||
case eRENDERDOC_Key_F7: ks = XK_F7; break;
|
||||
case eRENDERDOC_Key_F8: ks = XK_F8; break;
|
||||
case eRENDERDOC_Key_F9: ks = XK_F9; break;
|
||||
case eRENDERDOC_Key_F10: ks = XK_F10; break;
|
||||
case eRENDERDOC_Key_F11: ks = XK_F11; break;
|
||||
case eRENDERDOC_Key_F12: ks = XK_F12; break;
|
||||
case eRENDERDOC_Key_Home: ks = XK_Home; break;
|
||||
case eRENDERDOC_Key_End: ks = XK_End; break;
|
||||
case eRENDERDOC_Key_Insert: ks = XK_Insert; break;
|
||||
case eRENDERDOC_Key_Delete: ks = XK_Delete; break;
|
||||
case eRENDERDOC_Key_PageUp: ks = XK_Prior; break;
|
||||
case eRENDERDOC_Key_PageDn: ks = XK_Next; break;
|
||||
case eRENDERDOC_Key_Backspace: ks = XK_BackSpace; break;
|
||||
case eRENDERDOC_Key_Tab: ks = XK_Tab; break;
|
||||
case eRENDERDOC_Key_PrtScrn: ks = XK_Print; break;
|
||||
case eRENDERDOC_Key_Pause: ks = XK_Pause; break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if(ks == 0)
|
||||
return false;
|
||||
|
||||
xcb_keycode_t *keyCodes = xcb_key_symbols_get_keycode(symbols, ks);
|
||||
|
||||
if(!keyCodes)
|
||||
return false;
|
||||
|
||||
xcb_query_keymap_cookie_t keymapcookie = xcb_query_keymap(connection);
|
||||
xcb_query_keymap_reply_t *keys = xcb_query_keymap_reply(connection, keymapcookie, NULL);
|
||||
|
||||
bool ret = false;
|
||||
|
||||
if(keys && keyCodes[0] != XCB_NO_SYMBOL)
|
||||
{
|
||||
int byteIdx = (keyCodes[0]/8);
|
||||
int bitMask = 1 << (keyCodes[0]%8);
|
||||
|
||||
ret = (keys->keys[byteIdx] & bitMask) != 0;
|
||||
}
|
||||
|
||||
free(keyCodes);
|
||||
free(keys);
|
||||
|
||||
return ret;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
namespace FileIO
|
||||
{
|
||||
// in posix/.../..._stringio.cpp
|
||||
const char *GetTempRootPath();
|
||||
|
||||
string GetAppFolderFilename(const string &filename)
|
||||
{
|
||||
passwd *pw = getpwuid(getuid());
|
||||
@@ -283,12 +166,9 @@ namespace FileIO
|
||||
time_t t = time(NULL);
|
||||
tm now = *localtime(&t);
|
||||
|
||||
#ifdef ANDROID
|
||||
#define BASE_FOLDER "/sdcard"
|
||||
#else
|
||||
#define BASE_FOLDER "/tmp"
|
||||
#endif
|
||||
char temp_folder[2048] = { BASE_FOLDER };
|
||||
char temp_folder[2048] = { 0 };
|
||||
|
||||
strcpy(temp_folder, GetTempRootPath());
|
||||
|
||||
char *temp_override = getenv("RENDERDOC_TEMP");
|
||||
if(temp_override && temp_override[0] == '/')
|
||||
@@ -300,11 +180,11 @@ namespace FileIO
|
||||
|
||||
char temp_filename[2048] = {0};
|
||||
|
||||
snprintf(temp_filename, sizeof(temp_filename)-1, BASE_FOLDER "/%s_%04d.%02d.%02d_%02d.%02d.rdc", mod, 1900+now.tm_year, now.tm_mon+1, now.tm_mday, now.tm_hour, now.tm_min);
|
||||
snprintf(temp_filename, sizeof(temp_filename)-1, "%s/%s_%04d.%02d.%02d_%02d.%02d.rdc", GetTempRootPath(), mod, 1900+now.tm_year, now.tm_mon+1, now.tm_mday, now.tm_hour, now.tm_min);
|
||||
|
||||
capture_filename = string(temp_filename);
|
||||
|
||||
snprintf(temp_filename, sizeof(temp_filename)-1, BASE_FOLDER "/%s_%04d.%02d.%02d_%02d.%02d.%02d.log", logBaseName, 1900+now.tm_year, now.tm_mon+1, now.tm_mday, now.tm_hour, now.tm_min, now.tm_sec);
|
||||
snprintf(temp_filename, sizeof(temp_filename)-1, "%s/%s_%04d.%02d.%02d_%02d.%02d.%02d.log", GetTempRootPath(), logBaseName, 1900+now.tm_year, now.tm_mon+1, now.tm_mday, now.tm_hour, now.tm_min, now.tm_sec);
|
||||
|
||||
logging_filename = string(temp_filename);
|
||||
}
|
||||
@@ -424,65 +304,6 @@ namespace StringFormat
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
// cache iconv_t descriptor to save on iconv_open/iconv_close each time
|
||||
iconv_t iconvWide2UTF8 = (iconv_t)-1;
|
||||
|
||||
// iconv is not thread safe when sharing an iconv_t descriptor
|
||||
// I don't expect much contention but if it happens we could TryLock
|
||||
// before creating a temporary iconv_t, or hold two iconv_ts, or something.
|
||||
Threading::CriticalSection lockWide2UTF8;
|
||||
|
||||
string Wide2UTF8(const std::wstring &s)
|
||||
{
|
||||
// include room for null terminator, assuming unicode input (not ucs)
|
||||
// utf-8 characters can be max 4 bytes.
|
||||
size_t len = (s.length()+1)*4;
|
||||
|
||||
vector<char> charBuffer;
|
||||
|
||||
if(charBuffer.size() < len)
|
||||
charBuffer.resize(len);
|
||||
|
||||
size_t ret;
|
||||
|
||||
{
|
||||
SCOPED_LOCK(lockWide2UTF8);
|
||||
|
||||
#ifdef ANDROID
|
||||
ret = -1;
|
||||
#else
|
||||
if(iconvWide2UTF8 == (iconv_t)-1)
|
||||
iconvWide2UTF8 = iconv_open("UTF-8", "WCHAR_T");
|
||||
|
||||
if(iconvWide2UTF8 == (iconv_t)-1)
|
||||
{
|
||||
RDCERR("Couldn't open iconv for WCHAR_T to UTF-8: %d", errno);
|
||||
return "";
|
||||
}
|
||||
|
||||
char *inbuf = (char *)s.c_str();
|
||||
size_t insize = (s.length()+1)*sizeof(wchar_t); // include null terminator
|
||||
char *outbuf = &charBuffer[0];
|
||||
size_t outsize = len;
|
||||
|
||||
ret = iconv(iconvWide2UTF8, &inbuf, &insize, &outbuf, &outsize);
|
||||
#endif
|
||||
}
|
||||
|
||||
if(ret == (size_t)-1)
|
||||
{
|
||||
#if !defined(_RELEASE)
|
||||
RDCWARN("Failed to convert wstring");
|
||||
#endif
|
||||
return "";
|
||||
}
|
||||
|
||||
// convert to string from null-terminated string - utf-8 never contains
|
||||
// 0 bytes before the null terminator, and this way we don't care if
|
||||
// charBuffer is larger than the string
|
||||
return string(&charBuffer[0]);
|
||||
}
|
||||
};
|
||||
|
||||
namespace OSUtility
|
||||
@@ -1,8 +1,7 @@
|
||||
/******************************************************************************
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2015-2016 Baldur Karlsson
|
||||
* Copyright (c) 2014 Crytek
|
||||
* Copyright (c) 2016 Baldur Karlsson
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
+37
-23
@@ -266,8 +266,13 @@
|
||||
<ClInclude Include="maths\matrix.h" />
|
||||
<ClInclude Include="maths\quat.h" />
|
||||
<ClInclude Include="maths\vec.h" />
|
||||
<ClInclude Include="os\linux\linux_specific.h" />
|
||||
<ClInclude Include="os\os_specific.h" />
|
||||
<ClInclude Include="os\posix\posix_hook.h">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClInclude>
|
||||
<ClInclude Include="os\posix\posix_specific.h">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClInclude>
|
||||
<ClInclude Include="os\win32\win32_hook.h" />
|
||||
<ClInclude Include="os\win32\win32_specific.h" />
|
||||
<ClInclude Include="replay\replay_driver.h" />
|
||||
@@ -293,28 +298,37 @@
|
||||
<ClCompile Include="hooks\hooks.cpp" />
|
||||
<ClCompile Include="maths\camera.cpp" />
|
||||
<ClCompile Include="maths\matrix.cpp" />
|
||||
<ClCompile Include="os\linux\linux_callstack.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_hook.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_libentry.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_network.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_process.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_stringio.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_threading.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\os_specific.cpp" />
|
||||
<ClCompile Include="os\posix\android\android_callstack.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\android\android_stringio.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\linux\linux_callstack.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\linux\linux_stringio.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_hook.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_libentry.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_network.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_process.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_stringio.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_threading.cpp">
|
||||
<ExcludedFromBuild>true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\win32\sys_win32_hooks.cpp" />
|
||||
<ClCompile Include="os\win32\win32_callstack.cpp" />
|
||||
<ClCompile Include="os\win32\win32_hook.cpp" />
|
||||
@@ -415,4 +429,4 @@
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
</Project>
|
||||
|
||||
@@ -64,15 +64,21 @@
|
||||
<Filter Include="3rdparty\tinyexr">
|
||||
<UniqueIdentifier>{aadadb32-abbc-45b3-8f86-026eed994ba9}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="OS\Linux">
|
||||
<UniqueIdentifier>{5168e1dc-8d41-4aff-b99c-1ffa2af33f95}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Hooks">
|
||||
<UniqueIdentifier>{3e51a921-b167-4794-937d-e77573a928b8}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="Resources\spv">
|
||||
<UniqueIdentifier>{188ad934-e74f-4805-b74b-167f8760fab6}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="OS\Posix">
|
||||
<UniqueIdentifier>{410640a4-ebf0-479a-8d08-ae277e2ded84}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="OS\Posix\Linux">
|
||||
<UniqueIdentifier>{5168e1dc-8d41-4aff-b99c-1ffa2af33f95}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="OS\Posix\Android">
|
||||
<UniqueIdentifier>{16bdcbe1-31de-4732-aaaf-8d77039a26ec}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="maths\camera.h">
|
||||
@@ -234,12 +240,15 @@
|
||||
<ClInclude Include="common\custom_assert.h">
|
||||
<Filter>Common</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="os\linux\linux_specific.h">
|
||||
<Filter>OS\Linux</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="os\win32\win32_specific.h">
|
||||
<Filter>OS\Win32</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="os\posix\posix_hook.h">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClInclude>
|
||||
<ClInclude Include="os\posix\posix_specific.h">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="maths\camera.cpp">
|
||||
@@ -341,27 +350,6 @@
|
||||
<ClCompile Include="os\win32\win32_libentry.cpp">
|
||||
<Filter>OS\Win32</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_callstack.cpp">
|
||||
<Filter>OS\Linux</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_network.cpp">
|
||||
<Filter>OS\Linux</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_hook.cpp">
|
||||
<Filter>OS\Linux</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_process.cpp">
|
||||
<Filter>OS\Linux</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_stringio.cpp">
|
||||
<Filter>OS\Linux</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_threading.cpp">
|
||||
<Filter>OS\Linux</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\linux\linux_libentry.cpp">
|
||||
<Filter>OS\Linux</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\win32\sys_win32_hooks.cpp">
|
||||
<Filter>OS\Win32</Filter>
|
||||
</ClCompile>
|
||||
@@ -371,6 +359,36 @@
|
||||
<ClCompile Include="replay\capture_options.cpp">
|
||||
<Filter>Replay</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\android\android_callstack.cpp">
|
||||
<Filter>OS\Posix\Android</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\android\android_stringio.cpp">
|
||||
<Filter>OS\Posix\Android</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\linux\linux_callstack.cpp">
|
||||
<Filter>OS\Posix\Linux</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\linux\linux_stringio.cpp">
|
||||
<Filter>OS\Posix\Linux</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_hook.cpp">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_libentry.cpp">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_network.cpp">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_process.cpp">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_stringio.cpp">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="os\posix\posix_threading.cpp">
|
||||
<Filter>OS\Posix</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="os\win32\comexport.def">
|
||||
|
||||
Reference in New Issue
Block a user