mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Bump the index/vertex cpu-side buffer sizes a little. Replaces #17387
This commit is contained in:
parent
52b7bf502f
commit
c476d986f7
3 changed files with 10 additions and 3 deletions
|
@ -30,10 +30,14 @@
|
|||
|
||||
class VertexDecoder;
|
||||
|
||||
// int maxVerts = DECODED_VERTEX_BUFFER_SIZE / 2 / vertexSize; =~ 54000
|
||||
// 65536 * 6 * 2
|
||||
|
||||
|
||||
enum {
|
||||
VERTEX_BUFFER_MAX = 65536,
|
||||
DECODED_VERTEX_BUFFER_SIZE = VERTEX_BUFFER_MAX * 64,
|
||||
DECODED_INDEX_BUFFER_SIZE = VERTEX_BUFFER_MAX * 16,
|
||||
DECODED_VERTEX_BUFFER_SIZE = VERTEX_BUFFER_MAX * 2 * 36, // 36 == sizeof(SimpleVertex)
|
||||
DECODED_INDEX_BUFFER_SIZE = VERTEX_BUFFER_MAX * 6 * 6 * 2, // * 6 for spline tessellation, then * 6 again for converting into points/lines, and * 2 for 2 bytes per index
|
||||
};
|
||||
|
||||
enum {
|
||||
|
|
|
@ -548,7 +548,9 @@ void DrawEngineCommon::SubmitCurve(const void *control_points, const void *indic
|
|||
output.indices = decIndex;
|
||||
output.count = 0;
|
||||
|
||||
surface.Init(DECODED_VERTEX_BUFFER_SIZE / 2 / vertexSize);
|
||||
int maxVerts = DECODED_VERTEX_BUFFER_SIZE / 2 / vertexSize;
|
||||
|
||||
surface.Init(maxVerts);
|
||||
|
||||
if (CanUseHardwareTessellation(surface.primType)) {
|
||||
HardwareTessellation(output, surface, origVertType, points, tessDataTransfer);
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#define HALF_CEIL(x) (x + 1) / 2 // Integer ceil = (int)ceil((float)x / 2.0f)
|
||||
|
||||
// PSP compatible format so we can use the end of the pipeline in beziers etc
|
||||
// 8 + 4 + 12 + 12 = 36 bytes
|
||||
struct SimpleVertex {
|
||||
float uv[2];
|
||||
union {
|
||||
|
|
Loading…
Add table
Reference in a new issue