From bc269c270c0706fbafbe6bac34a9f163efa274cb Mon Sep 17 00:00:00 2001 From: chyyran Date: Tue, 20 Aug 2024 22:10:47 -0400 Subject: [PATCH] rt(d3d9): remove backtrace from Direct3DError --- librashader-runtime-d3d9/src/draw_quad.rs | 8 +++++++- librashader-runtime-d3d9/src/error.rs | 7 +------ librashader-runtime-d3d9/src/lib.rs | 1 - 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/librashader-runtime-d3d9/src/draw_quad.rs b/librashader-runtime-d3d9/src/draw_quad.rs index 74f8c78..2962e52 100644 --- a/librashader-runtime-d3d9/src/draw_quad.rs +++ b/librashader-runtime-d3d9/src/draw_quad.rs @@ -6,7 +6,13 @@ use librashader_runtime::quad::{QuadType, VertexInput}; use windows::Win32::Foundation::FALSE; -use windows::Win32::Graphics::Direct3D9::{IDirect3DDevice9, IDirect3DVertexBuffer9, IDirect3DVertexDeclaration9, D3DCMP_ALWAYS, D3DCULL_NONE, D3DDECLMETHOD_DEFAULT, D3DDECLTYPE_FLOAT2, D3DDECLTYPE_FLOAT3, D3DDECLTYPE_UNUSED, D3DDECLUSAGE_TEXCOORD, D3DPOOL_DEFAULT, D3DPT_TRIANGLESTRIP, D3DRS_CLIPPING, D3DRS_CULLMODE, D3DRS_LIGHTING, D3DRS_ZENABLE, D3DRS_ZFUNC, D3DTRANSFORMSTATETYPE, D3DTS_PROJECTION, D3DTS_VIEW, D3DVERTEXELEMENT9, D3DRS_COLORWRITEENABLE}; +use windows::Win32::Graphics::Direct3D9::{ + IDirect3DDevice9, IDirect3DVertexBuffer9, IDirect3DVertexDeclaration9, D3DCMP_ALWAYS, + D3DCULL_NONE, D3DDECLMETHOD_DEFAULT, D3DDECLTYPE_FLOAT2, D3DDECLTYPE_FLOAT3, + D3DDECLTYPE_UNUSED, D3DDECLUSAGE_TEXCOORD, D3DPOOL_DEFAULT, D3DPT_TRIANGLESTRIP, + D3DRS_CLIPPING, D3DRS_COLORWRITEENABLE, D3DRS_CULLMODE, D3DRS_LIGHTING, D3DRS_ZENABLE, + D3DRS_ZFUNC, D3DTRANSFORMSTATETYPE, D3DTS_PROJECTION, D3DTS_VIEW, D3DVERTEXELEMENT9, +}; const OFFSCREEN_VBO_DATA: [VertexInput; 4] = [ VertexInput { diff --git a/librashader-runtime-d3d9/src/error.rs b/librashader-runtime-d3d9/src/error.rs index 865ac83..90bf50d 100644 --- a/librashader-runtime-d3d9/src/error.rs +++ b/librashader-runtime-d3d9/src/error.rs @@ -4,7 +4,6 @@ use librashader_preprocess::PreprocessError; use librashader_presets::ParsePresetError; use librashader_reflect::error::{ShaderCompileError, ShaderReflectError}; use librashader_runtime::image::ImageError; -use std::backtrace::Backtrace; use std::string::FromUtf8Error; use thiserror::Error; @@ -14,11 +13,7 @@ pub enum FilterChainError { #[error("invariant assumption about d3d11 did not hold. report this as an issue.")] Direct3DOperationError(&'static str), #[error("direct3d driver error")] - Direct3DError { - #[from] - error: windows::core::Error, - backtrace: Backtrace, - }, + Direct3DError(#[from] windows::core::Error), #[error("shader preset parse error")] ShaderPresetError(#[from] ParsePresetError), #[error("shader preprocess error")] diff --git a/librashader-runtime-d3d9/src/lib.rs b/librashader-runtime-d3d9/src/lib.rs index 45066a8..fe16a26 100644 --- a/librashader-runtime-d3d9/src/lib.rs +++ b/librashader-runtime-d3d9/src/lib.rs @@ -1,6 +1,5 @@ #![cfg(target_os = "windows")] #![feature(type_alias_impl_trait)] -#![feature(error_generic_member_access)] mod binding; mod d3dx; mod draw_quad;