class SMAA {
public:
class ExternalStorage;
enum Mode { MODE_SMAA_1X, MODE_SMAA_T2X, MODE_SMAA_S2X, MODE_SMAA_4X };
enum Preset { PRESET_LOW, PRESET_MEDIUM, PRESET_HIGH, PRESET_ULTRA, PRESET_CUSTOM };
enum Input { INPUT_LUMA, INPUT_COLOR, INPUT_DEPTH };
/**
* By default, two render targets will be created for storing
* intermediate calculations. If you have spare render targets,
* search for @EXTERNAL_STORAGE.
*/
SMAA(ID3D10Device *device, int width, int height,
Preset preset = PRESET_HIGH,bool predication = false, bool reprojection = false,
const ExternalStorage &storage=ExternalStorage()); //此處為報錯位
~SMAA();
class ExternalStorage {
public:
ExternalStorage(ID3D10ShaderResourceView *edgesSRV=NULL,
ID3D10RenderTargetView *edgesRTV=NULL,
ID3D10ShaderResourceView *weightsSRV=NULL,
ID3D10RenderTargetView *weightsRTV=NULL)
: edgesSRV(edgesSRV),
edgesRTV(edgesRTV),
weightsSRV(weightsSRV),
weightsRTV(weightsRTV) {}
ID3D10ShaderResourceView *edgesSRV, *weightsSRV;
ID3D10RenderTargetView *edgesRTV, *weightsRTV;
};
uj5u.com熱心網友回復:
解決問題了再加50分都么得問題啊
,頭都要禿了
uj5u.com熱心網友回復:
編譯環境為win10,vs2015uj5u.com熱心網友回復:
你沒有實作默認建構式因此不能
myclass *m1;
m1 = new myclass
uj5u.com熱心網友回復:
我重構了默認建構式后
,就會報錯,沒有合適的默認建構式可用
uj5u.com熱心網友回復:
"SMAA::ExternalStorage":沒有合適的默認建構式可用
uj5u.com熱心網友回復:
把后面的定義放到前面就不報這個錯了了class SMAA {
public:
class ExternalStorage {
public:
ExternalStorage(ID3D10ShaderResourceView *edgesSRV=NULL,
ID3D10RenderTargetView *edgesRTV=NULL,
ID3D10ShaderResourceView *weightsSRV=NULL,
ID3D10RenderTargetView *weightsRTV=NULL)
: edgesSRV(edgesSRV),
edgesRTV(edgesRTV),
weightsSRV(weightsSRV),
weightsRTV(weightsRTV) {}
ID3D10ShaderResourceView *edgesSRV, *weightsSRV;
ID3D10RenderTargetView *edgesRTV, *weightsRTV;
};
enum Mode { MODE_SMAA_1X, MODE_SMAA_T2X, MODE_SMAA_S2X, MODE_SMAA_4X };
enum Preset { PRESET_LOW, PRESET_MEDIUM, PRESET_HIGH, PRESET_ULTRA, PRESET_CUSTOM };
enum Input { INPUT_LUMA, INPUT_COLOR, INPUT_DEPTH };
/**
* By default, two render targets will be created for storing
* intermediate calculations. If you have spare render targets,
* search for @EXTERNAL_STORAGE.
*/
SMAA(ID3D10Device *device, int width, int height,
Preset preset = PRESET_HIGH,bool predication = false, bool reprojection = false,
const ExternalStorage &storage=ExternalStorage()); //此處為報錯位
~SMAA();
轉載請註明出處,本文鏈接:https://www.uj5u.com/houduan/72834.html
標籤:C++ 語言
上一篇:如何查看下載的專案
