How to use bluprint or c++ to set the render mode in the game : WireFrame Lit ???
afaik… there’s no native wireframe mode ingame. you can only use it in a debug build.
you’ll have to get the source and mod it to allow it ingame in a release build.
or you write some custom code and shaders to generate wireframe meshes. the quad look. or triangles. tris don’t do it for most game applications, tho. hmm
How do I access the c++ code for rendering a frame in Unreal.
When I was writing my own engine,
technically DirectX allows you to make the WireFrame mode “SetRenderState”.
well… w/e… maybe just use this switch. it’s the ugly triangle wireframe. only works for organic games.
How to open a file Render.cpp in the first photo,
where can I find these files,
what is in the first photo?
you never opened the engine code?
just open the project and search in the folders or search for keywords in files for what you require.
i, for example, searched for “WIREFRAME” to get to the renderstate/rasterizerstate and traced it backward to the drawing function (the current function name is in the top center-ish).
the thing “marked” is 1 of 2 lines of code (you can see in the search results at the bottom) that are able to create the rasterizerstate to throw it into the shader system in the line below.
the project view is not really relevant. i just tried to remember where i messed with drawing code the last time. you can try to manual dig thru those folders and try to find rendering things. it’s a lil bit scattered, cause many people coding it and it’s lots of wrapping code for multiplatform and multiapi development. it’s kinda normal.
either way… i can only give you this hint. i obviously won’t code it for you. it’s diy coding for what you need. or… just use the normal wireframe material switch. i was not aware that it actually works.
that’s about it.
I didn’t understand where to look, in the Unreal editor?
the normal wireframe switch is in the material editor. i thought the screenshot with the search box made that very clear.
if that wireframe display is good enough for your use case you don’t need to worry about c++. just blueprint a material switch for the objects you need to change.
if you need a global wireframe switch you may have to get creative tho.
How to open engine code?
SetEditorViewportViewMode needs an editor viewport as input. i don’t know if you could clone it and run it without the WITH_EDITOR condition. just try it. write code to test it. it’s not that hard. you coded an engine? figure out the epic codestyle and modify it. it’s defo not dx9/10. it’s dx11/12.
in general: if you have built the engine and obviously have the source on your computer and link visual studo in the code editor settings you can double click on the functions and it will open the c++file. you could easily figure this out.
or i guess you’re not very proficient to edit c++ code? is unreal too much for you? maybe?
hmm
Why does the wireframe material not work in the smartphone after packaging the project in apk format for Android?