Hi all, I know it may sound idiot as I have zero knowledge on 3d graphics but is it possible to make wined3d to not add textures to things resulting in a sort of wireframe renderer?
The long and uninteresting background: I used to play a game called X-moto in 300Mhz Celeron Linux computer, in its standard rendering mode it was impossible to play the game due to low fps, but it had an awesome wireframe mode that played smoothly. So if this could be achieved globally by wined3d we could play new games on old computers (my overly noob conclusion about all this).
Thanks in advance for any reply, Bruno
You'd probably have to hack into the game to change the rasterizer state to wireframe mode. Many game trainers (basically memory hacks which are used for cheating) offer D3D hooks which allow you to *switch on* wireframe mode, but that depends on the DX version too. AFAIK many DX9 onwards games have trainers like this available. Anyways, wined3d as it is right now can't decide the rasterizer state of any game by itself. wined3d will merely do what the game tells it to do, so you'll have to modify the game itself (via methods like the one described above), or if you have the source-code of the game, then change its default rasterizer state. fwiw, I don't advocate the former method as it's basically cheating in-game.
Cheers, Aaryaman
On Tue, Sep 29, 2015 at 7:01 PM, Bruno Jesus 00cpxxx@gmail.com wrote:
Hi all, I know it may sound idiot as I have zero knowledge on 3d graphics but is it possible to make wined3d to not add textures to things resulting in a sort of wireframe renderer?
The long and uninteresting background: I used to play a game called X-moto in 300Mhz Celeron Linux computer, in its standard rendering mode it was impossible to play the game due to low fps, but it had an awesome wireframe mode that played smoothly. So if this could be achieved globally by wined3d we could play new games on old computers (my overly noob conclusion about all this).
Thanks in advance for any reply, Bruno
Have a look at dlls/wined3d/state.c, state_fillmode().
However, you're likely to run into two problems:
1) The game doesn't necessarily clear the color buffer and just re-render every pixel. You'll have to change swapchain_present to clear the back buffer, otherwise you'll just get a colorful mess of old lines and new lines.
2) Render-to-texture: In modern games it is common to render everything to one or more textures, and then draw the texture onto the back buffer with one or more post-processing draws. You'll somehow have to figure out the post processing draws and make them non-wireframe, otherwise you'll end up with a mostly empty screen.
Point 2 also makes point 1 more difficult to solve. You'll have to find the intermediate render targets, clear them, and also find a proper clear color that produces a "good" result with the post processing shaders.
Also, Aaryaman's information is also pretty accurate: There may be external programs, and if you are dealing with an online game expect to be booted from the game pretty quickly because of attempted cheating...
Re performance: Wireframe mode will only fix games that are limited by fragment processing. If you're CPU bound (which is the case in Wine most of the time without CSMT) you'll gain absolutely nothing. Also vertex processing limted setups won't improve, but those are fairly rare. If you're truly fragment processing limited lowering the resolution should help...
Cheers, Stefan
Am 29.09.2015 um 15:52 schrieb Aaryaman Vasishta jem456.vasishta@gmail.com:
You'd probably have to hack into the game to change the rasterizer state to wireframe mode. Many game trainers (basically memory hacks which are used for cheating) offer D3D hooks which allow you to *switch on* wireframe mode, but that depends on the DX version too. AFAIK many DX9 onwards games have trainers like this available. Anyways, wined3d as it is right now can't decide the rasterizer state of any game by itself. wined3d will merely do what the game tells it to do, so you'll have to modify the game itself (via methods like the one described above), or if you have the source-code of the game, then change its default rasterizer state. fwiw, I don't advocate the former method as it's basically cheating in-game.
Cheers, Aaryaman
On Tue, Sep 29, 2015 at 7:01 PM, Bruno Jesus 00cpxxx@gmail.com wrote: Hi all, I know it may sound idiot as I have zero knowledge on 3d graphics but is it possible to make wined3d to not add textures to things resulting in a sort of wireframe renderer?
The long and uninteresting background: I used to play a game called X-moto in 300Mhz Celeron Linux computer, in its standard rendering mode it was impossible to play the game due to low fps, but it had an awesome wireframe mode that played smoothly. So if this could be achieved globally by wined3d we could play new games on old computers (my overly noob conclusion about all this).
Thanks in advance for any reply, Bruno
On 2015.09.29 17:15, Stefan Dösinger wrote: [...]
Re performance: Wireframe mode will only fix games that are limited by fragment processing. If you're CPU bound (which is the case in Wine most of the time without CSMT) you'll gain absolutely nothing. Also vertex processing limted setups won't improve, but those are fairly rare. If you're truly fragment processing limited lowering the resolution should help...
Cheers, Stefan
I experimented with making some games run in wireframe under wine around a year ago and can say the results can be quite disappointing in some cases, with performance dropping by an order of magnitude. In some cases, objects that normally get culled due to being occluded by other objects suddenly become visible in wireframe, and thus, get rendered. Since this can lead to processing *a lot* of objects that don't get processed otherwise, it can choke the CPU up badly.
note: I'm no expert; just writing from experience.
On Tue, Sep 29, 2015 at 9:20 PM, Gediminas Jakutis gediminas@varciai.lt wrote:
On 2015.09.29 17:15, Stefan Dösinger wrote: [...]
Re performance: Wireframe mode will only fix games that are limited by
fragment processing. If you're CPU bound (which is the case in Wine most of the time without CSMT) you'll gain absolutely nothing. Also vertex processing limted setups won't improve, but those are fairly rare. If you're truly fragment processing limited lowering the resolution should help...
Cheers, Stefan
I experimented with making some games run in wireframe under wine around a year ago and can say the results can be quite disappointing in some cases, with performance dropping by an order of magnitude. In some cases, objects that normally get culled due to being occluded by other objects suddenly become visible in wireframe, and thus, get rendered. Since this can lead to processing *a lot* of objects that don't get processed otherwise, it can choke the CPU up badly.
note: I'm no expert; just writing from experience.
-- Gediminas Jakutis LDK Varčiai www.varciai.lt
While you have a point, but (theoretically, judging from Bruno's experience in the game X-moto) texture mapping might be more exacting than rendering all vertices together without texture mapping in some cases. Though I'm not sure about it myself.
Cheers, Aaryaman
Am 29.09.2015 um 18:12 schrieb Aaryaman Vasishta jem456.vasishta@gmail.com:
While you have a point, but (theoretically, judging from Bruno's experience in the game X-moto) texture mapping might be more exacting than rendering all vertices together without texture mapping in some cases. Though I'm not sure about it myself.
Note that wireframe rendering doesn't disable texture mapping. It just assembles the vertices to geometry in a different way. Instead of filling the entire triangle defined by the vertices it just fills the lines between the vertices. The lines that are drawn still have the normal fragment processing (including shaders and textures) applied.
On Wed, Sep 30, 2015 at 2:47 AM, Stefan Dösinger stefandoesinger@gmail.com wrote:
Am 29.09.2015 um 18:12 schrieb Aaryaman Vasishta < jem456.vasishta@gmail.com>:
While you have a point, but (theoretically, judging from Bruno's
experience in the game X-moto) texture mapping might be more exacting than rendering all vertices together without texture mapping in some cases. Though I'm not sure about it myself. Note that wireframe rendering doesn't disable texture mapping. It just assembles the vertices to geometry in a different way. Instead of filling the entire triangle defined by the vertices it just fills the lines between the vertices. The lines that are drawn still have the normal fragment processing (including shaders and textures) applied.
Right, my bad, I forgot to mention that.
Thanks everyone, I really appreciate all the replies.
On Wednesday, September 30, 2015, Aaryaman Vasishta < jem456.vasishta@gmail.com> wrote:
On Wed, Sep 30, 2015 at 2:47 AM, Stefan Dösinger < stefandoesinger@gmail.com javascript:_e(%7B%7D,'cvml','stefandoesinger@gmail.com');> wrote:
Am 29.09.2015 um 18:12 schrieb Aaryaman Vasishta < jem456.vasishta@gmail.com javascript:_e(%7B%7D,'cvml','jem456.vasishta@gmail.com');>:
While you have a point, but (theoretically, judging from Bruno's
experience in the game X-moto) texture mapping might be more exacting than rendering all vertices together without texture mapping in some cases. Though I'm not sure about it myself. Note that wireframe rendering doesn't disable texture mapping. It just assembles the vertices to geometry in a different way. Instead of filling the entire triangle defined by the vertices it just fills the lines between the vertices. The lines that are drawn still have the normal fragment processing (including shaders and textures) applied.
Right, my bad, I forgot to mention that.
Yeah this really won’t work well if the goal is to speed up games on older hardware. As noted, if you are GPU bound then reducing the resolution should help.
-Matt
On Sep 29, 2015, at 11:50 AM, Gediminas Jakutis gediminas@varciai.lt wrote:
On 2015.09.29 17:15, Stefan Dösinger wrote: [...]
Re performance: Wireframe mode will only fix games that are limited by fragment processing. If you're CPU bound (which is the case in Wine most of the time without CSMT) you'll gain absolutely nothing. Also vertex processing limted setups won't improve, but those are fairly rare. If you're truly fragment processing limited lowering the resolution should help...
Cheers, Stefan
I experimented with making some games run in wireframe under wine around a year ago and can say the results can be quite disappointing in some cases, with performance dropping by an order of magnitude. In some cases, objects that normally get culled due to being occluded by other objects suddenly become visible in wireframe, and thus, get rendered. Since this can lead to processing *a lot* of objects that don't get processed otherwise, it can choke the CPU up badly.
note: I'm no expert; just writing from experience.
-- Gediminas Jakutis LDK Varčiai www.varciai.lt
Yeah this really won’t work well if the goal is to speed up games on older hardware. As noted, if you are GPU bound then reducing the resolution should help.
-Matt
On Sep 29, 2015, at 11:50 AM, Gediminas Jakutis gediminas@varciai.lt wrote:
On 2015.09.29 17:15, Stefan Dösinger wrote: [...]
Re performance: Wireframe mode will only fix games that are limited by fragment processing. If you're CPU bound (which is the case in Wine most of the time without CSMT) you'll gain absolutely nothing. Also vertex processing limted setups won't improve, but those are fairly rare. If you're truly fragment processing limited lowering the resolution should help...
Cheers, Stefan
I experimented with making some games run in wireframe under wine around a year ago and can say the results can be quite disappointing in some cases, with performance dropping by an order of magnitude. In some cases, objects that normally get culled due to being occluded by other objects suddenly become visible in wireframe, and thus, get rendered. Since this can lead to processing *a lot* of objects that don't get processed otherwise, it can choke the CPU up badly.
note: I'm no expert; just writing from experience.
-- Gediminas Jakutis LDK Varčiai www.varciai.lt