Sign in to follow this  

Which is the diference between surface and texture

This topic is 2636 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hey mate,

Maybe you should have a read through this:

hhttp://en.wikipedia.org/wiki/Computer_graphics#Concepts_and_principles

Quote:
Texture mapping
Texture mapping is a method for adding detail, surface texture, or colour to a computer-generated graphic or 3D model. Its application to 3D graphics was pioneered by Dr Edwin Catmull in 1974. A texture map is applied (mapped) to the surface of a shape, or polygon.


Let me know if you have any specific questions!

Cheers,
Bach

Share this post


Link to post
Share on other sites
Quote:
Original post by thebach
Hey mate,

Maybe you should have a read through this:

hhttp://en.wikipedia.org/wiki/Computer_graphics#Concepts_and_principles

Quote:
Texture mapping
Texture mapping is a method for adding detail, surface texture, or colour to a computer-generated graphic or 3D model. Its application to 3D graphics was pioneered by Dr Edwin Catmull in 1974. A texture map is applied (mapped) to the surface of a shape, or polygon.


Let me know if you have any specific questions!

Cheers,
Bach


i don´t have it clear. So if i have a 3d model i can render it with either a surface or a texture?

Share this post


Link to post
Share on other sites
I think he is talking about the difference between Direct3D textures and surfaces.

Needforhint best describes it on this forum http://forums.xna.com/forums/p/15292/80148.aspx:

"texture is a c++ object allocated in system memory while surface is a member of this object, allocated in video memory,"

The MSDN library confirms this.

"A surface represents a linear area of display memory and usually resides in the display memory of the display card, although surfaces can exist in system memory.",
http://msdn.microsoft.com/en-us/library/bb219683(v=VS.85).aspx

Needforhint also states that surfaces can be locked for further operations which would bring them down to system memory.

Share this post


Link to post
Share on other sites
Quote:
Original post by tariqwalji

I think he is talking about the difference between Direct3D textures and surfaces.

Needforhint best describes it on this forum http://forums.xna.com/forums/p/15292/80148.aspx:

"texture is a c++ object allocated in system memory while surface is a member of this object, allocated in video memory,"


yes i was talking about that, because i was using slimdx to convert textures between differnt dxt types but i can only do it with surfaces and not with textures, and i don´t understand why i can convert surfaces to the dxt type that i want and why i can´t do the same with textures

Share this post


Link to post
Share on other sites
Quote:
Original post by jor1980
yes i was talking about that, because i was using slimdx to convert textures between differnt dxt types but i can only do it with surfaces and not with textures, and i don´t understand why i can convert surfaces to the dxt type that i want and why i can´t do the same with textures
A texture is a collection of one or more surfaces, one for each mip level. Both surfaces and textures can be stored in system or video memory.

If you want to convert a texture from one format to another, you need to iterate through each surface level (In C++ that's done with the GetSurfaceLevel() function, and GetDesc() to get the number of surfaces in it), and convert each surface level in turn.

Share this post


Link to post
Share on other sites

This topic is 2636 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this