mirror of
https://github.com/AxioDL/metaforce.git
synced 2025-12-08 15:04:56 +00:00
Remaining object tracker platforms
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
#ifndef NOMINMAX
|
||||
#define NOMINMAX
|
||||
#endif
|
||||
#define WIN_PAUSE 1
|
||||
#define WIN_PAUSE 0
|
||||
#include <objbase.h>
|
||||
#endif
|
||||
|
||||
|
||||
2
hecl/extern/boo
vendored
2
hecl/extern/boo
vendored
Submodule hecl/extern/boo updated: 3a7987bb21...6c3a35f15d
@@ -302,7 +302,7 @@ static inline int Rename(const SystemChar* oldpath, const SystemChar* newpath)
|
||||
{
|
||||
#if HECL_UCS2
|
||||
//return _wrename(oldpath, newpath);
|
||||
return ReplaceFileW(newpath, oldpath, nullptr, 0, nullptr, nullptr) == 0;
|
||||
return MoveFileExW(oldpath, newpath, MOVEFILE_REPLACE_EXISTING | MOVEFILE_WRITE_THROUGH) == 0;
|
||||
#else
|
||||
return rename(oldpath, newpath);
|
||||
#endif
|
||||
|
||||
@@ -635,7 +635,7 @@ struct SPIRVBackendFactory : IShaderBackendFactory
|
||||
const hecl::Frontend::IR& ir,
|
||||
hecl::Frontend::Diagnostics& diag,
|
||||
boo::IGraphicsDataFactory::Context& ctx,
|
||||
boo::IShaderPipeline*& objOut)
|
||||
boo::ObjToken<boo::IShaderPipeline>& objOut)
|
||||
{
|
||||
m_backend.reset(ir, diag);
|
||||
|
||||
@@ -704,8 +704,9 @@ struct SPIRVBackendFactory : IShaderBackendFactory
|
||||
return dataOut;
|
||||
}
|
||||
|
||||
boo::IShaderPipeline* buildShaderFromCache(const ShaderCachedData& data,
|
||||
boo::IGraphicsDataFactory::Context& ctx)
|
||||
boo::ObjToken<boo::IShaderPipeline>
|
||||
buildShaderFromCache(const ShaderCachedData& data,
|
||||
boo::IGraphicsDataFactory::Context& ctx)
|
||||
{
|
||||
const ShaderTag& tag = data.m_tag;
|
||||
athena::io::MemoryReader r(data.m_data.get(), data.m_sz, false, false);
|
||||
@@ -731,7 +732,7 @@ struct SPIRVBackendFactory : IShaderBackendFactory
|
||||
if (r.hasError())
|
||||
return nullptr;
|
||||
|
||||
boo::IShaderPipeline* ret =
|
||||
boo::ObjToken<boo::IShaderPipeline> ret =
|
||||
static_cast<boo::VulkanDataFactory::Context&>(ctx).
|
||||
newShaderPipeline(nullptr, nullptr,
|
||||
&vertBlob, &fragBlob, &pipelineBlob,
|
||||
@@ -777,7 +778,7 @@ struct SPIRVBackendFactory : IShaderBackendFactory
|
||||
tag.getReflectionType(), slot.lighting, slot.post, slot.texCount, slot.texs);
|
||||
pipeBlobs.emplace_back();
|
||||
Blobs& pipeBlob = pipeBlobs.back();
|
||||
boo::IShaderPipeline* ret =
|
||||
boo::ObjToken<boo::IShaderPipeline> ret =
|
||||
static_cast<boo::VulkanDataFactory::Context&>(ctx).
|
||||
newShaderPipeline(vertSource.c_str(), fragSource.c_str(),
|
||||
&pipeBlob.vert, &pipeBlob.frag, &pipeBlob.pipeline,
|
||||
@@ -894,7 +895,7 @@ struct SPIRVBackendFactory : IShaderBackendFactory
|
||||
break;
|
||||
}
|
||||
|
||||
boo::IShaderPipeline* ret =
|
||||
boo::ObjToken<boo::IShaderPipeline> ret =
|
||||
static_cast<boo::VulkanDataFactory::Context&>(ctx).
|
||||
newShaderPipeline(nullptr, nullptr,
|
||||
&vertBlob, &fragBlob, &pipelineBlob,
|
||||
|
||||
@@ -360,7 +360,7 @@ struct HLSLBackendFactory : IShaderBackendFactory
|
||||
const hecl::Frontend::IR& ir,
|
||||
hecl::Frontend::Diagnostics& diag,
|
||||
boo::IGraphicsDataFactory::Context& ctx,
|
||||
boo::IShaderPipeline*& objOut)
|
||||
boo::ObjToken<boo::IShaderPipeline>& objOut)
|
||||
{
|
||||
m_backend.reset(ir, diag);
|
||||
|
||||
@@ -431,8 +431,9 @@ struct HLSLBackendFactory : IShaderBackendFactory
|
||||
return dataOut;
|
||||
}
|
||||
|
||||
boo::IShaderPipeline* buildShaderFromCache(const ShaderCachedData& data,
|
||||
boo::IGraphicsDataFactory::Context& ctx)
|
||||
boo::ObjToken<boo::IShaderPipeline>
|
||||
buildShaderFromCache(const ShaderCachedData& data,
|
||||
boo::IGraphicsDataFactory::Context& ctx)
|
||||
{
|
||||
const ShaderTag& tag = data.m_tag;
|
||||
athena::io::MemoryReader r(data.m_data.get(), data.m_sz, false, false);
|
||||
@@ -469,7 +470,7 @@ struct HLSLBackendFactory : IShaderBackendFactory
|
||||
if (r.hasError())
|
||||
return nullptr;
|
||||
|
||||
boo::IShaderPipeline* ret =
|
||||
boo::ObjToken<boo::IShaderPipeline> ret =
|
||||
static_cast<boo::ID3DDataFactory::Context&>(ctx).
|
||||
newShaderPipeline(nullptr, nullptr,
|
||||
ReferenceComPtr(vertBlob), ReferenceComPtr(fragBlob), ReferenceComPtr(pipelineBlob),
|
||||
@@ -534,7 +535,7 @@ struct HLSLBackendFactory : IShaderBackendFactory
|
||||
break;
|
||||
}
|
||||
|
||||
boo::IShaderPipeline* ret =
|
||||
boo::ObjToken<boo::IShaderPipeline> ret =
|
||||
static_cast<boo::ID3DDataFactory::Context&>(ctx).
|
||||
newShaderPipeline(vertSource.c_str(), fragSource.c_str(),
|
||||
ReferenceComPtr(thisPipeBlobs.vert), ReferenceComPtr(thisPipeBlobs.frag), ReferenceComPtr(thisPipeBlobs.pipeline),
|
||||
@@ -654,7 +655,7 @@ struct HLSLBackendFactory : IShaderBackendFactory
|
||||
break;
|
||||
}
|
||||
|
||||
boo::IShaderPipeline* ret =
|
||||
boo::ObjToken<boo::IShaderPipeline> ret =
|
||||
static_cast<boo::ID3DDataFactory::Context&>(ctx).
|
||||
newShaderPipeline(nullptr, nullptr,
|
||||
ReferenceComPtr(vertBlob), ReferenceComPtr(fragBlob), ReferenceComPtr(pipelineBlob),
|
||||
|
||||
@@ -187,7 +187,7 @@ bool Project::ConfigFile::unlockAndCommit()
|
||||
{
|
||||
#if HECL_UCS2
|
||||
//_wrename(newPath.c_str(), m_filepath.c_str());
|
||||
ReplaceFileW(m_filepath.c_str(), newPath.c_str(), nullptr, 0, nullptr, nullptr);
|
||||
MoveFileExW(newPath.c_str(), m_filepath.c_str(), MOVEFILE_REPLACE_EXISTING | MOVEFILE_WRITE_THROUGH);
|
||||
#else
|
||||
rename(newPath.c_str(), m_filepath.c_str());
|
||||
#endif
|
||||
|
||||
@@ -108,6 +108,8 @@ void SanitizePath(std::string& path)
|
||||
}
|
||||
return a;
|
||||
});
|
||||
while (path.back() == '/')
|
||||
path.pop_back();
|
||||
}
|
||||
|
||||
static const std::wstring WIllegals {L"<>?\"|"};
|
||||
@@ -140,6 +142,8 @@ void SanitizePath(std::wstring& path)
|
||||
}
|
||||
return a;
|
||||
});
|
||||
while (path.back() == L'/')
|
||||
path.pop_back();
|
||||
}
|
||||
|
||||
static std::mutex PathsMutex;
|
||||
|
||||
Reference in New Issue
Block a user