- Fix link resolution with proper relative/absolute path handling - Improve link styling with underline decoration - Hide leaf nodes from tree, only show directories - Fix log file path for packaged app
27 lines
560 B
Markdown
27 lines
560 B
Markdown
# OpenGLBuffer::Initialize
|
|
|
|
```cpp
|
|
bool Initialize(OpenGLBufferType type, size_t size, const void* data = nullptr, bool dynamic = false);
|
|
```
|
|
|
|
初始化 OpenGL 缓冲区。
|
|
|
|
**参数:**
|
|
- `type` - 缓冲区类型
|
|
- `size` - 缓冲区大小(字节)
|
|
- `data` - 初始数据指针(可选)
|
|
- `dynamic` - 是否为动态缓冲区
|
|
|
|
**返回:** 成功返回 true
|
|
|
|
**示例:**
|
|
|
|
```cpp
|
|
OpenGLBuffer buffer;
|
|
buffer.Initialize(OpenGLBufferType::Vertex, sizeof(vertices), vertices);
|
|
```
|
|
|
|
## 相关文档
|
|
|
|
- [OpenGLBuffer 总览](buffer.md) - 返回类总览
|