Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (AndrewAMD, Ayumi), 1,266 guests, and 5 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
ent_setvertex #298533
11/15/09 20:56
11/15/09 20:56
Joined: Jan 2007
Posts: 2,247
Deutsch Niedersachsen
Puppeteer Offline OP
Expert
Puppeteer  Offline OP
Expert

Joined: Jan 2007
Posts: 2,247
Deutsch Niedersachsen
Why isn't it yet possible to modify the normals with ent_setvertex?
If it was possible it would be an easy to make groups of models seamless.


Formally known as Omega
Avatar randomness by Quadraxas & Blade
http://omegapuppeteer.mybrute.com
Re: ent_setvertex [Re: Puppeteer] #298538
11/15/09 21:30
11/15/09 21:30
Joined: Jun 2008
Posts: 151
Ukraine
XD1v0 Offline
Member
XD1v0  Offline
Member

Joined: Jun 2008
Posts: 151
Ukraine
Hi, with ent_setvertex you already can change any vertex value also the normals, but under word "normals" what you mean(?), normal what affect on triangle shading or normal what responsible for culling process?

Last edited by XD1v0; 11/15/09 21:31.

A7 Commercial cool
Celeron 1700, GeForce 5500 FX 256mb, 1 Gb Ram
Re: ent_setvertex [Re: XD1v0] #298540
11/15/09 21:34
11/15/09 21:34
Joined: Jan 2007
Posts: 2,247
Deutsch Niedersachsen
Puppeteer Offline OP
Expert
Puppeteer  Offline OP
Expert

Joined: Jan 2007
Posts: 2,247
Deutsch Niedersachsen
I mean contact.nx it should be responsible for triangle shading.
EDIT: checked it multiple times now. Editing the normals is not possible.

Last edited by Puppeteer; 11/15/09 21:47.

Formally known as Omega
Avatar randomness by Quadraxas & Blade
http://omegapuppeteer.mybrute.com
Re: ent_setvertex [Re: Puppeteer] #298543
11/15/09 22:00
11/15/09 22:00
Joined: Jun 2008
Posts: 151
Ukraine
XD1v0 Offline
Member
XD1v0  Offline
Member

Joined: Jun 2008
Posts: 151
Ukraine
Try this code, this code set all vertices normals to single normal
Code:
void set_all_normals (ENTITY* this,VECTOR* _normal)
{
 int num = ent_status (this,1);
 int c = 0;
 CONTACT* cont = 0;
 for (;c<num;c++)
{
 cont = ent_getvertex(this,NULL,c);
 cont.v.nx = _normal.x; 
 cont.v.ny = _normal.z;// DX coord to GS
 cont.v.nz = _normal.y;// DX coord to GS
}

}




A7 Commercial cool
Celeron 1700, GeForce 5500 FX 256mb, 1 Gb Ram
Re: ent_setvertex [Re: XD1v0] #298561
11/16/09 00:32
11/16/09 00:32
Joined: Jan 2007
Posts: 2,247
Deutsch Niedersachsen
Puppeteer Offline OP
Expert
Puppeteer  Offline OP
Expert

Joined: Jan 2007
Posts: 2,247
Deutsch Niedersachsen
Okay but if i use ent_setvertex ever again the old normals will reappear.
Thank you.
Why does it work anyway without enet_setvertex?

Last edited by Puppeteer; 11/16/09 00:33.

Formally known as Omega
Avatar randomness by Quadraxas & Blade
http://omegapuppeteer.mybrute.com
Re: ent_setvertex [Re: Puppeteer] #298590
11/16/09 09:41
11/16/09 09:41
Joined: Jun 2008
Posts: 151
Ukraine
XD1v0 Offline
Member
XD1v0  Offline
Member

Joined: Jun 2008
Posts: 151
Ukraine
Quote:
Why does it work anyway without enet_setvertex?

Because ent_getvertex give you pointer to vertex that uses in original mesh( mesh what uses for rendering), so you do not need use ent_setvertex anymore wink

Last edited by XD1v0; 11/16/09 09:42.

A7 Commercial cool
Celeron 1700, GeForce 5500 FX 256mb, 1 Gb Ram

Moderated by  old_bill, Tobias 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1