我想繪製一個大網格的網格(想想〜120k頂點)。 如果我嘗試將所有頂點放在單個索引緩衝區中,它將無法工作,因爲我使用的是java.nio.ShortBuffer
作爲索引緩衝區,所以最大值爲2^15 - 1,而我需要〜2^17個頂點。我應該將我的網格分成多個部分嗎?我可以使用Buffer
的其他子類作爲GL10.glDrawElements
的第四個參數嗎?Android中的Big IndexBuffer
1
A
回答
1
大規模編輯下面的miniBill評論!
實際上,OpenGL-ES僅支持GL_UNSIGNED_BYTE
或GL_UNSIGNED_SHORT
索引。 最常用的是GL_UNSIGNED_SHORT
它允許2^16-1頂點。其他類型只被OpenGL支持。
您還可以使用
GL_INT
或
GL_UNSIGNED_INT
的指數,我想它,你可以在一個
java.nio.IntBuffer
存儲。
看起來你需要拆分幾何。
相關問題
- 1. android big decimal approximation
- 2. 分配一個NSUInteger IndexBuffer
- 3. 錯誤XNA框架VertexBuffer IndexBuffer用法
- 4. 在谷歌Big Query中識別空閒事件Big Query.existing procedure
- 5. 在PHP中解析BIG XML
- 6. 屏幕中心BIG DIV
- 7. 在MATLAB中實現big int
- 8. Big Commerce博客
- 9. Erlang和Big Numbers
- 10. php json_encode big array
- 11. NodeJS&Big Json Data
- 12. Big-O算法
- 13. Google Big table
- 14. kmeans with big data
- 15. Big Renaming Project
- 16. Collection.Contains Big-O
- 17. PostgreSQL + Big CSV
- 18. Big Theta計算
- 19. Big Mod算法
- 20. Big Redis設置
- 21. 尋找Big Theta
- 22. Big Arrays and identifiers
- 23. Big Commerce ReferenceError&InvalidStateError
- 24. iPhone SDK - Big UITableViewCell
- 25. Big Query cache
- 26. modf()with BIG NUMBERS
- 27. rsync git big repository
- 28. Image Scaled Big
- 29. big-endian && little -endian?
- 30. Matrix Big O Notation
你指的是哪個'IndexBuffer'?這並不是嚴格意義上的opengl-es的一部分。 – rotoglup
那麼,opengl-es可能是一個錯誤的標籤。實際上,我輸入錯了:我的意思是'java.nio.ShortBuffer'用作第四個參數ogf'GL10.glDrawElements'。讓我編輯 – miniBill