Tag Info

New answers tagged

1

What you could do is use a pool of big VBOs, with a PoolManager. The PoolManager would only allocate "big" VBOs, each one having the same size, for example 4/16/256MB, not sure of how much vertex data you have... Each VBO in the PoolManager would have associated lists of "used" and "free" regions (a region is defined by an offset from VBO start and a ...


4

Non-array struct members for constant buffers in HLSL are packed on four byte offsets, as many as it can into 16-byte vectors. If a member would straddle a vector boundary, it starts a new vector. You cannot achieve this with just an alignment and pack directive, you need to have explicit padding in your CPU-side structure to emulate the CB layout rules. ...


0

I believe your DEAOColor crosses the 16 byte alignment boundary. Your first bool is 4 bytes so DEAOColor get's cut in two. Try switching them (and any other variable that doesn't fit within the 16 byte steps).


0

Simulating the whole world in real time on a single PC is unlikely to be possible. What you could do, however, is split your world in several chunks (I mean chunks, not shards). You'd have to adapt your world for an agent (AI) to be able to exist in a single chunk at any given time. For instance, you could have one big island per chunk. And then you ...


1

No. Not at least from what you're describing. An AI that's unique to one animal that takes into account all of the variables of such a complex environment would be taxing to simulate just on it's own. Plant life would be easier, but the cost to simulate all the plants would add up fast. A continuous simulation of the entire ecosystem would be virtually ...


8

Out of curiosity (and peace of the mind...) I wondered how DirectX decides which attribute from a struct corresponds to the right variable inside an HLSL cbuffer-register(x) (apart from the order/type they are declared with). Purely through memory layout. You give D3D a pointer to a chunk of memory which you claim to be organized in a certain ...


1

My assumption based on my experiences with shader reflection in DX11 is that it's mapped by name. If you check out the DX11 shader reflection API you'll see that there is a D3D11_SHADER_VARIABLE_DESC struct that you can rip from the shader. Notice the LPCSTR for the name of the variable. OpenGL also handles variable mapping by name. Of course the best way ...



Top 50 recent answers are included