Canvas Wireframe color

Discussions about Coding and Scripting
Post Reply
User avatar
Feralidragon
Godlike
Posts: 5493
Joined: Wed Feb 27, 2008 6:24 pm
Personal rank: Work In Progress
Location: Liandri

Canvas Wireframe color

Post by Feralidragon »

So, here's a question (hoping someone can answer):
in Canvas the DrawActor method has the option to render as wireframe, is it possible to change the color of the wireframe itself?

I tried to change Canvas.DrawColor and no effect, I went to the editor wireframe colors preferences and change them and no effect, the wireframe keeps always as brown.
So, is the wireframe color value saved somewhere (and which I can tweak from UScript), or is it hardcoded nativelly somewhere or does the color depends on graphic drivers or ...?

I find it quite hard to believe Epic would be as dumb as implementing the wireframe option and not be able to even change its color from the canvas or some other way (since without being able to define the color this feature is quite useless).


EDIT: For what is worth, I have investigated this a bit better and I found that it seems that the wireframe color is really hardcoded nativelly, thus not being possible to modify the color (dumb move Epic, I still wonder why they implemented it in the first place)...

However, if someone finds this statement untrue and knows how to change it from UScript, please post here, in meanwhile, it seems I have to go with plan B.
User avatar
Shadow
Masterful
Posts: 743
Joined: Tue Jan 29, 2008 12:00 am
Personal rank: Mad Carpenter
Location: Germany
Contact:

Re: Canvas Wireframe color

Post by Shadow »

It's not possible to modify the color unless you write a drawactor function on your own. The color is simply saved locally within the function. You cannot change it with Unreal Script.
Image
User avatar
Feralidragon
Godlike
Posts: 5493
Joined: Wed Feb 27, 2008 6:24 pm
Personal rank: Work In Progress
Location: Liandri

Re: Canvas Wireframe color

Post by Feralidragon »

Thanks for confirming this Shadow :)

Well, I guess I really have to go with plan B afterall....
User avatar
Shadow
Masterful
Posts: 743
Joined: Tue Jan 29, 2008 12:00 am
Personal rank: Mad Carpenter
Location: Germany
Contact:

Re: Canvas Wireframe color

Post by Shadow »

How does your plane be look like?
Image
User avatar
Feralidragon
Godlike
Posts: 5493
Joined: Wed Feb 27, 2008 6:24 pm
Personal rank: Work In Progress
Location: Liandri

Re: Canvas Wireframe color

Post by Feralidragon »

Well, to explain plan B I have to explain plan A.

I am currently doing a weapon called Ionizer, and the first thing you have to do with it is to deploy a station which will launch a rocket up to the sky with a satellite in it (the satellite would be used to fire an ion beam in the end to the place you pointed with the Ionizer). The thing is, I want players to see how the station will be deployed in realtime as they choose a place for it to be, and the way I thought was using a wireframed station with different colors: green you can deploy there, red would couldn't (because of the inclination, or other factors).

Plan B... well, I had 2 plans "B" sort of to speak: one was to use the UVs antialiased lines (since I did/do all my models, I have the source UVs), this give me the advantage to tweak the "wireframe" so I can hide certain unwanted/cluttering "wires" (to look cleaner), OR I can simply apply a single color to the launcher, then making it translucent and giving a low scaleglow level and I still get a good effect and gameplay/usage factor.

From those 2 plans "B", I will go with the second (one color and translucency+low scaleglow), because there's another weapon I will make which you can deploy/spawn all kinds of things (if previouslly configured that is), and so my first plan B is not suitable for it and I like to normalize things between weapons.
User avatar
papercoffee
Godlike
Posts: 10447
Joined: Wed Jul 15, 2009 11:36 am
Personal rank: coffee addicted !!!
Location: Cologne, the city with the big cathedral.
Contact:

Re: Canvas Wireframe color

Post by papercoffee »

another Idea ...what about a skin with the wire frame on it. Like a remapped UV-map. you make the model from two sides visible and the texture masked or translucent.

EDIT----------------------------------------------------------------
Oh never mind ... you got already that idea... :|
Feralidragon wrote: Plan B... well, I had 2 plans "B" sort of to speak: one was to use the UVs antialiased lines (since I did/do all my models, I have the source UVs), this give me the advantage to tweak the "wireframe" so I can hide certain unwanted/cluttering "wires" (to look cleaner)
Maybe a mix of your two plan B's... could work pretty well.
User avatar
Feralidragon
Godlike
Posts: 5493
Joined: Wed Feb 27, 2008 6:24 pm
Personal rank: Work In Progress
Location: Liandri

Re: Canvas Wireframe color

Post by Feralidragon »

papercoffee wrote: Maybe a mix of your two plan B's... could work pretty well.
You know what? That's exactly what I am going to do :mrgreen:
User avatar
Shadow
Masterful
Posts: 743
Joined: Tue Jan 29, 2008 12:00 am
Personal rank: Mad Carpenter
Location: Germany
Contact:

Re: Canvas Wireframe color

Post by Shadow »

I suggest you may use the MeshEmitter coming with this Month's Beta. It has an option to render the particle mesh as wireframe model, with dynamic color. Exactly what you need, and it's fast. Same for the StaticMeshActor, it's already able to draw as wireframe, but I didn't implement dynamic color, the color is cyan by standard. But your both plans are a good solution either.
Image
User avatar
Feralidragon
Godlike
Posts: 5493
Joined: Wed Feb 27, 2008 6:24 pm
Personal rank: Work In Progress
Location: Liandri

Re: Canvas Wireframe color

Post by Feralidragon »

Thanks Shadow. :D

However, at least for this specific pack (this is for Nali Weapons 3) I won't be using anything from your SDK, and reason is that I am aiming for this pack to be fully compatible with nothing more than a fresh installed UT v436, with no Bonus packs dependencies nor other external dependencies (so I am not even using skeletal animation yet, I am still using vertex, it sucks but at least no one will complain about not being able to run the pack from the start), so that anyone can run the pack right out of the box, but that info is very usefull since I may use your SDK though for something bigger I am aiming to do since I started to make mods for the game, where I will need wireframed models for certain "somethings" :mrgreen:

Either ways I already did a "wireframed" skin (one green and another red), and I can already launch the rocket (screens coming soon on how it ended up looking).
User avatar
Shadow
Masterful
Posts: 743
Joined: Tue Jan 29, 2008 12:00 am
Personal rank: Mad Carpenter
Location: Germany
Contact:

Re: Canvas Wireframe color

Post by Shadow »

I can understand your opinion. Thus I'm even more eager to hear about your "something bigger", I'm really curious! UT currently really lacks some bigger mods, currently developed big mods or Total Conversions are delaying for... partially 5 years now.
Image
User avatar
Saya-chan
Adept
Posts: 446
Joined: Mon Jun 02, 2008 10:46 am
Personal rank: Former UT99 modder
Location: Vigo, Galicia
Contact:

Re: Canvas Wireframe color

Post by Saya-chan »

Oh my! That's awesome.
Image
  ~♥~ Bless the Cute Emperor ~♥~
User avatar
Hook
Inhuman
Posts: 754
Joined: Tue Apr 22, 2008 11:21 pm
Personal rank: UT99 Promoter/Admin
Location: Minnesota USA
Contact:

Re: Canvas Wireframe color

Post by Hook »

Ah, Feralidragon, that is so wise to stay with default UT99 compatibility. :gj:
I have seen a lot of players going back to pure UT "vanilla" fun that they "grew up with".
=Hook=(Member# 626)
HUTP Active Forums: https://hooksutplace.freeforums.net/forum
HUTP UT99 Community Portal: https://hooksutplace.freeforums.net/
OR: https://hermskii.com/hook/ut99_hutp/
UT99 Server -> CROSSBONES Missile Madness {CMM}

* Newest Versions of: PRO-Redeemers | PRO-SNIPER-Redeemers | PRO-SEEKER-Redeemers <-(the Original)
and Now with FOOD FIGHT and Frying Pan arena !!!
IP: 68.232.181.236:7777 <-(NEW IP to come)
UT99 MH Server -> {CMH} CROSSBONES Monster Hunt (MH) by Mars007 (The Original) - IP: 108.61.238.93:7777
User avatar
Saya-chan
Adept
Posts: 446
Joined: Mon Jun 02, 2008 10:46 am
Personal rank: Former UT99 modder
Location: Vigo, Galicia
Contact:

Re: Canvas Wireframe color

Post by Saya-chan »

I literally grew up with it. :lol2:
Image
  ~♥~ Bless the Cute Emperor ~♥~
User avatar
EvilGrins
Godlike
Posts: 9695
Joined: Thu Jun 30, 2011 8:12 pm
Personal rank: God of Fudge
Location: Palo Alto, CA
Contact:

Re: Canvas Wireframe color

Post by EvilGrins »

This is a bit out of my field, but despite what's been said above I do believe it's possible to change the colorization of the wireframe. There's a wireframe skin for the Male Soldier and I've a monsterhunt map where it presents some of the monsters in a wireframe format.
http://unreal-games.livejournal.com/
Image
medor wrote:Replace Skaarj with EvilGrins :mrgreen:
Smilies · viewtopic.php?f=8&t=13758
Post Reply