Re: [hlcoders] Modifying the Shadow engine..

2007-01-19 Thread Skillet
--
[ Picked text/plain from multipart/alternative ]
Don't forget about the upcoming Episode 2 lighting and shadowing overhaul.
http://en.wikipedia.org/wiki/Source_Engine#Dynamic_lighting_and_shadowing_2

If you can wait for that it will probably be better than anything that can
be done practically with just the SDK code.

On 1/19/07, Minh <[EMAIL PROTECTED]> wrote:
>
> This is a multi-part message in MIME format.
> --
> [ Picked text/plain from multipart/alternative ]
> Hey guys,
> I've been thinking of the possibility of improving the shadow
> rendering in the Source engine. Currently, it seems all entities in the
> world cast their shadows from a single light source ( defined in
> "r_shadowangle" ).
> Realistically, each entity should cast their shadows based on the
> nearest dominant light source (like it's done in the Unreal engine). I'm not
> sure how feasible it would be to rework the current shadow engine to take
> into account an entities nearest light source so I'm just wondering if
> anyone has looked into this.
> Has anyone attempted such a feat? or knows of the limitations of the
> shadow engine that would complicate such an endeavour?
> --
>
>
> ___
> To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>
--

___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] Modifying the Shadow engine..

2007-01-19 Thread Adam \"amckern\" Mckern
Your just meaning give props a shadow based on the
light source?

There are problems with this let me give you a few:
1) If you gib a prop, the shadow will need to be
updated for every single gib, as it moves in each
frame

2) Picking up a prop will have to have the same effect
applied, but it will be cheaper (not as many parts
needs to be updated)

3) If a room has flickering lights, and they are all
spaced equally around the prop, your going to run into
the high cost of calculating what one draws, and from
where.

I think some of us would love to see a dynamic shadow
engine like Doom 3, and UE3, but I don’t think the
source engine will be able to do it with in a
reasonable cost.

Adam


--- Minh <[EMAIL PROTECTED]> wrote:

> This is a multi-part message in MIME format.
> --
> [ Picked text/plain from multipart/alternative ]
> Hey guys,
> I've been thinking of the possibility of
> improving the shadow rendering in the Source engine.
> Currently, it seems all entities in the world cast
> their shadows from a single light source ( defined
> in "r_shadowangle" ).
> Realistically, each entity should cast their
> shadows based on the nearest dominant light source
> (like it's done in the Unreal engine). I'm not sure
> how feasible it would be to rework the current
> shadow engine to take into account an entities
> nearest light source so I'm just wondering if anyone
> has looked into this.
> Has anyone attempted such a feat? or knows of
> the limitations of the shadow engine that would
> complicate such an endeavour?
> --
>
>
> ___
> To unsubscribe, edit your list preferences, or view
> the list archives, please visit:
>
http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>



Nigredo Studios http://www.nigredostudios.com




No need to miss a message. Get email on-the-go
with Yahoo! Mail for Mobile. Get started.
http://mobile.yahoo.com/mail

___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



[hlcoders] Modifying the Shadow engine..

2007-01-19 Thread Minh
This is a multi-part message in MIME format.
--
[ Picked text/plain from multipart/alternative ]
Hey guys,
I've been thinking of the possibility of improving the shadow rendering in 
the Source engine. Currently, it seems all entities in the world cast their 
shadows from a single light source ( defined in "r_shadowangle" ).
Realistically, each entity should cast their shadows based on the nearest 
dominant light source (like it's done in the Unreal engine). I'm not sure how 
feasible it would be to rework the current shadow engine to take into account 
an entities nearest light source so I'm just wondering if anyone has looked 
into this.
Has anyone attempted such a feat? or knows of the limitations of the shadow 
engine that would complicate such an endeavour?
--


___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] How to Vectors work?

2007-01-19 Thread Jeremy
--
[ Picked text/plain from multipart/alternative ]
Vectors hold a position x,y,z or a direction x,y,z. Although they could also
use them to store yaw pitch and roll valve created a seperate class for that
I believe, QAngle.

What they hold depends on where you get the value from.

CBaseEntity::GetAbsOrigin() will give you back a vector with an absolute
world position.
There is also GetLocalOrigin which will give you a local positional offset
from something you are parented to. I've not used this much, but I  would
assume that might be an offset from a vehicle you are in, maybe an elevator
or moving platform or something, though I could be wrong.

CBaseEntity::GetAbsVelocity: Velocity is often expressed as a direction
vector as well, with the length of the vector representing the speed. As a
simple example, an entities position will be updated by some code like
position += velocity * deltaTime; In this case the length of the velocity
vector is significant. To get just the direction without the 'speed'
component you would normalize the vector.

Some purely directional attributes of entities operate from a normalized
vector. HL2 stores many of its directions in the QAngle class. For example,
CBaseEntity::EyeAngles() returns a QAngle, which I normally convert to a
directional vector because I find them easier to work with.

Vector vFwd, vRight, vUp;
QAngle viewAngles = pEntity->EyeAngles();
AngleVectors(viewAngles, &vFwd, &vRight, &vUp);

Most useful in this case is the vFwd vector, so you can optionally pass null
to the right and up parameters to save a bit of work.

Vectors are overall pretty nice and easy to work with, though if you are
brand new to them it will probably take more than this to start getting
comfortable with them. If you have specific questions about things feel free
to post them but(and I don't mean this rudely), it's unlikely someone is
going to go very in depth explaining a basic mathematical tool like vectors.

J

On 1/19/07, Mukkan Yhtiö <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> Could some one explain how Vector Vatriables work? As far as I know they
> hold (x, y and z) coordinates?
>
> If I wanted to manually manipulate a Vector Variable in game I need to
> know
> how they work mathimatically? What they hold entirely and how to
> manipulate
> them in a 3D environment.
>
> I assume when manipulating 3D objects in a 3D environment you use yaw,
> pitch
> and roll as well as x, y and z?
>
> If anyone could briefly explain all this to me I would be eternally
> greatfull.
>
> Thanks.
>
> _
> Express yourself instantly with MSN Messenger! Download today it's FREE!
> http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
>
>
> ___
> To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>
--

___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] How to Vectors work?

2007-01-19 Thread Jeffrey \"botman\" Broome

Chris Harris wrote:

--
[ Picked text/plain from multipart/alternative ]
I suggest to get a book dealing with Linear Algebra... Though be warned it
is Calculus 2 and 3 topics so it may be hard or not (depends). Linear
Algebra is the math of vectors and it basically an invaluable tool for doing
3d engine work. Many natural phenomena that you may need to do are possible
with some simple equations from the book.


GameDev.net has some excellent articles on Math and Physics...

http://www.gamedev.net/reference/list.asp?categoryid=28

...see the "Subcategory: Vectors" section

--
Jeffrey "botman" Broome

___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] How to Vectors work?

2007-01-19 Thread Chris Harris
--
[ Picked text/plain from multipart/alternative ]
I suggest to get a book dealing with Linear Algebra... Though be warned it
is Calculus 2 and 3 topics so it may be hard or not (depends). Linear
Algebra is the math of vectors and it basically an invaluable tool for doing
3d engine work. Many natural phenomena that you may need to do are possible
with some simple equations from the book.

On 1/19/07, Joel R. <[EMAIL PROTECTED]> wrote:
>
> --
> [ Picked text/plain from multipart/alternative ]
> In math vectors are used to define "direction".  But in c++ theres a class
> called Vector which holds 3 points.  [0],[1],[2] or .x,.y,.z or
> [PITCH],[YAW],[ROLL]  All the same exact thing, just 3 different ways of
> setting the variables, usually whatever comes easier to the coder.  I like
> using .x/.y/.z myself.
>
> First you have origins, the point in the world 3D grid that something is
> located at.
> Lets say i have a guy at point ( 0, 0, 10 ).  Our guy is on the z axis
> (up)
> 10 units. Simple.
> Velocity uses the same Vector class but is used as a direction.  The
> amount
> given is how many units it will move in one second according to the values
> in each axis.
> Lets say I'm at (0,0,0) and I want to move to our guy in 2 seconds. Our
> velocity would be (0,0,5).
>
> In the code they do soemthing like this.
>
> Vector origin = pEntity->GetAbsOrigin();
> Vector velocity = Vector(0,0,5);
>
> origin += velocity * gpGlobals->frametime;
>
> pEntity->SetAbsOrigin( origin );
>
> This is basically what the movement system does.  Velocity is just a
> helper
> to know your movement speed and direction.
> Origin is what really counts as thats where your model will be located at.
>
> Hope that helps =)
>
>
> On 1/19/07, Mukkan Yhtiö <[EMAIL PROTECTED]> wrote:
> >
> > Hi,
> >
> > Could some one explain how Vector Vatriables work? As far as I know they
> > hold (x, y and z) coordinates?
> >
> > If I wanted to manually manipulate a Vector Variable in game I need to
> > know
> > how they work mathimatically? What they hold entirely and how to
> > manipulate
> > them in a 3D environment.
> >
> > I assume when manipulating 3D objects in a 3D environment you use yaw,
> > pitch
> > and roll as well as x, y and z?
> >
> > If anyone could briefly explain all this to me I would be eternally
> > greatfull.
> >
> > Thanks.
> >
> > _
> > Express yourself instantly with MSN Messenger! Download today it's FREE!
> > http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
> >
> >
> > ___
> > To unsubscribe, edit your list preferences, or view the list archives,
> > please visit:
> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> >
> >
> --
>
> ___
> To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>
--

___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



Re: [hlcoders] How to Vectors work?

2007-01-19 Thread Joel R.
--
[ Picked text/plain from multipart/alternative ]
In math vectors are used to define "direction".  But in c++ theres a class
called Vector which holds 3 points.  [0],[1],[2] or .x,.y,.z or
[PITCH],[YAW],[ROLL]  All the same exact thing, just 3 different ways of
setting the variables, usually whatever comes easier to the coder.  I like
using .x/.y/.z myself.

First you have origins, the point in the world 3D grid that something is
located at.
Lets say i have a guy at point ( 0, 0, 10 ).  Our guy is on the z axis (up)
10 units. Simple.
Velocity uses the same Vector class but is used as a direction.  The amount
given is how many units it will move in one second according to the values
in each axis.
Lets say I'm at (0,0,0) and I want to move to our guy in 2 seconds. Our
velocity would be (0,0,5).

In the code they do soemthing like this.

Vector origin = pEntity->GetAbsOrigin();
Vector velocity = Vector(0,0,5);

origin += velocity * gpGlobals->frametime;

pEntity->SetAbsOrigin( origin );

This is basically what the movement system does.  Velocity is just a helper
to know your movement speed and direction.
Origin is what really counts as thats where your model will be located at.

Hope that helps =)


On 1/19/07, Mukkan Yhtiö <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> Could some one explain how Vector Vatriables work? As far as I know they
> hold (x, y and z) coordinates?
>
> If I wanted to manually manipulate a Vector Variable in game I need to
> know
> how they work mathimatically? What they hold entirely and how to
> manipulate
> them in a 3D environment.
>
> I assume when manipulating 3D objects in a 3D environment you use yaw,
> pitch
> and roll as well as x, y and z?
>
> If anyone could briefly explain all this to me I would be eternally
> greatfull.
>
> Thanks.
>
> _
> Express yourself instantly with MSN Messenger! Download today it's FREE!
> http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
>
>
> ___
> To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>
--

___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders



[hlcoders] How to Vectors work?

2007-01-19 Thread Mukkan Yhti

Hi,

Could some one explain how Vector Vatriables work? As far as I know they
hold (x, y and z) coordinates?

If I wanted to manually manipulate a Vector Variable in game I need to know
how they work mathimatically? What they hold entirely and how to manipulate
them in a 3D environment.

I assume when manipulating 3D objects in a 3D environment you use yaw, pitch
and roll as well as x, y and z?

If anyone could briefly explain all this to me I would be eternally
greatfull.

Thanks.

_
Express yourself instantly with MSN Messenger! Download today it's FREE!
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/


___
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders