This commit is contained in:
Ben Vanik 2014-11-08 11:38:07 -08:00
parent 21b6c93db0
commit a4141e84ce
3 changed files with 15 additions and 7 deletions

View File

@ -26,7 +26,9 @@ public:
void OnStreamEnd() {} void OnStreamEnd() {}
void OnVoiceProcessingPassEnd() {} void OnVoiceProcessingPassEnd() {}
void OnVoiceProcessingPassStart(uint32_t samples_required) {} void OnVoiceProcessingPassStart(uint32_t samples_required) {}
void OnBufferEnd(void* context); void OnBufferEnd(void* context) {
SetEvent(wait_handle_);
}
void OnBufferStart(void* context) {} void OnBufferStart(void* context) {}
void OnLoopEnd(void* context) {} void OnLoopEnd(void* context) {}
void OnVoiceError(void* context, HRESULT result) {} void OnVoiceError(void* context, HRESULT result) {}
@ -35,10 +37,6 @@ private:
HANDLE wait_handle_; HANDLE wait_handle_;
}; };
void XAudio2AudioDriver::VoiceCallback::OnBufferEnd(void* context) {
SetEvent(wait_handle_);
}
XAudio2AudioDriver::XAudio2AudioDriver(Emulator* emulator, HANDLE wait) : XAudio2AudioDriver::XAudio2AudioDriver(Emulator* emulator, HANDLE wait) :
audio_(0), mastering_voice_(0), pcm_voice_(0), audio_(0), mastering_voice_(0), pcm_voice_(0),
wait_handle_(wait), voice_callback_(0), wait_handle_(wait), voice_callback_(0),

View File

@ -172,6 +172,9 @@ void GraphicsSystem::WriteRegister(uint64_t addr, uint64_t value) {
case 0x0714: // CP_RB_WPTR case 0x0714: // CP_RB_WPTR
command_processor_->UpdateWritePointer((uint32_t)value); command_processor_->UpdateWritePointer((uint32_t)value);
break; break;
case 0x6110: // ? swap related?
XELOGW("Unimplemented GPU register %.4X write: %.8X", r, value);
return;
default: default:
XELOGW("Unknown GPU register %.4X write: %.8X", r, value); XELOGW("Unknown GPU register %.4X write: %.8X", r, value);
break; break;

View File

@ -154,11 +154,20 @@ bool TextureResource::Info::Prepare(const xe_gpu_texture_fetch_t& fetch,
info.is_compressed = true; info.is_compressed = true;
break; break;
case FMT_DXT1_AS_16_16_16_16: case FMT_DXT1_AS_16_16_16_16:
// TODO(benvanik): conversion?
info.format = DXGI_FORMAT_BC1_UNORM; info.format = DXGI_FORMAT_BC1_UNORM;
info.block_size = 4; info.block_size = 4;
info.texel_pitch = 8; info.texel_pitch = 8;
info.is_compressed = true; info.is_compressed = true;
break; break;
case FMT_DXT2_3_AS_16_16_16_16:
case FMT_DXT4_5_AS_16_16_16_16:
// TODO(benvanik): conversion?
info.format = DXGI_FORMAT_BC3_UNORM;
info.block_size = 4;
info.texel_pitch = 16;
info.is_compressed = true;
break;
case FMT_1_REVERSE: case FMT_1_REVERSE:
case FMT_1: case FMT_1:
case FMT_5_6_5: case FMT_5_6_5:
@ -199,8 +208,6 @@ bool TextureResource::Info::Prepare(const xe_gpu_texture_fetch_t& fetch,
case FMT_16_MPEG_INTERLACED: case FMT_16_MPEG_INTERLACED:
case FMT_16_16_MPEG_INTERLACED: case FMT_16_16_MPEG_INTERLACED:
case FMT_DXN: case FMT_DXN:
case FMT_DXT2_3_AS_16_16_16_16:
case FMT_DXT4_5_AS_16_16_16_16:
case FMT_2_10_10_10_AS_16_16_16_16: case FMT_2_10_10_10_AS_16_16_16_16:
case FMT_10_11_11_AS_16_16_16_16: case FMT_10_11_11_AS_16_16_16_16:
case FMT_11_11_10_AS_16_16_16_16: case FMT_11_11_10_AS_16_16_16_16: