# How to upload the vertex buffer of custom struct to GPU and how to use it when want to render the object with the vertices?

**URL:** <https://forums.unrealengine.com/t/how-to-upload-the-vertex-buffer-of-custom-struct-to-gpu-and-how-to-use-it-when-want-to-render-the-object-with-the-vertices/415882>\
**Category:** Rendering\
**Tags:** gpu, unreal-engine, Rendering, Shaders, hlsl, CPP, question\
**Created:** [January 30, 2018, 7:12am UTC](https://forums.unrealengine.com/t/how-to-upload-the-vertex-buffer-of-custom-struct-to-gpu-and-how-to-use-it-when-want-to-render-the-object-with-the-vertices/415882 "2018-01-30T07:12:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ming\_qi](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ming\_qi](https://forums.unrealengine.com/u/ming_qi)\
**Post date:** [January 30, 2018, 7:12am UTC](https://forums.unrealengine.com/t/how-to-upload-the-vertex-buffer-of-custom-struct-to-gpu-and-how-to-use-it-when-want-to-render-the-object-with-the-vertices/415882/1 "2018-01-30T07:12:03Z")

</div>

I want to use C++ and HLSL to test vertex shader and fragment shader .And some parts have been completed, but i encounter some problems .I am not familiar with UE4 , for which I don’t know how to upload the vertex buffer of the custom struct to GPU （just like vertex buffer in OpenGL) and how to use it when i want to render the object with the vertices.  
How it used in UE4 or is there any tutorials ?
