Questions tagged [textures]

Textures are series of images used in computer graphics to associate locations on a visible surface with varying values. This association is typically done by mapping locations on the texture (usually two-dimensional, but other dimensions and types of textures exist) to locations on the rendered surface. Filtering is often used to smooth away aliasing when sampling values from the texture, usually involving multiple images within a texture called mipmaps.

In 3D graphics, the digital representation of the surface of an object. In addition to two-dimensional qualities, such as color and brightness, a texture is also encoded with three-dimensional properties, such as how transparent and reflective the object is. Once a texture has been defined, it can be wrapped around any 3-dimensional object. This is called texture mapping.

Well-defined textures are very important for rendering realistic 3-D images. However, they also require a lot of memory, so they're not used as often as they might be. This is one of the rationales for the development of the new graphics interface, AGP, which allows texture to be stored in main memory, which is more expansive than video memory. AGP also speeds up the transfer of large textures between memory, the CPU and the video adapter.

5888 questions
2
votes
0 answers

Multi-threaded texture upload with D3D11

i am currently developing an application which shows multiple video streams concurrently. The decoding happens part in hardware via DXVA2/Intel Media SDK and in part in sofware via ffmpeg. The rendering of the decoded frames is done entirely in…
youaresoomean
  • 296
  • 3
  • 9
2
votes
1 answer

OpenGL Texture and Object Streaming

I have a need to stream a texture (essentially a camera feed). With object streaming, the following scenarios seem to be arise: Is the new object's data store larger, smaller or same size as the old one? Subset of or whole texture being…
Protongun
  • 3,230
  • 1
  • 15
  • 13
2
votes
1 answer

using multiple textures in libgdx efficiently

im new to libgdx I've been using it for only 2 weeks. my problem is with understanding how texture loading works. i managed to load my first texture (a player) using gdx.files.internal(player.png) or something along those lines and it worked fine, i…
RooneyMUFC
  • 103
  • 2
  • 11
2
votes
3 answers

Debugging a basic OpenGL texture fail? (iphone)

I have a very basic texture map problem in GL on iPhone, and I'm wondering what strategies there are for debugging this kind of thing. (Frankly, just staring at state machine calls and wondering if any of them is wrong or misordered is no way to…
Ben Zotto
  • 70,108
  • 23
  • 141
  • 204
2
votes
1 answer

Trying to switch a texture when player dies (OpenGL + C++)

I'm creating a 2D game and when the player dies I want the texture I to switch to another (to show an explosion) I also want the game to pause for a second or two so the user can see that the texture has changed. My textures are loading correctly…
Chris
  • 3,036
  • 5
  • 36
  • 53
2
votes
2 answers

WebCamTexture iOS blurry snapshot

I am currently using the WebCamTexture class to display live camera feed until the user takes a snapshot, and then I use said snapshot as a Texture in my app. Here's the code I'm using at the moment : private WebCamTexture cameraTexture; private…
Bypp
  • 331
  • 3
  • 22
2
votes
1 answer

How to create texture using DirectX-11 with DXGI_FORMAT_420_OPAQUE format?

I am facing problems creating DirectX texture from I420 data. My program crashes when I try to add texture. I am working on windows 8.0 on a WinRT metro app. Can you help me please? My code is as follows: D3D11_TEXTURE2D_DESC texDesc =…
2
votes
2 answers

How to make sharp textures in cocos2d-x

I have a plain image data (32 bit RGBA) of size in a char array and want to make a cocos2d-x Texture2D out of it as in: Texture2D * tex = new Texture2D(); tex->initWithData(data, 4*size.width*size.height, Texture2D::PixelFormat::RGBA8888,size.width,…
user3648895
  • 395
  • 10
  • 20
2
votes
1 answer

LibGDX Texture Packer

I am trying to use LibGDX's texture packer gui for making a texture atlas of tiles for a video game. But I keep getting alpha bleed and I am wondering how to prevent that from happening? I have tried all the different filters and the only one which…
Scott Kingdon
  • 351
  • 1
  • 2
  • 9
2
votes
1 answer

Non-radial texture mapping over a ring geometry in WebGL using Three.js

I am trying to simulate image deformation effects using textures over 2D geomtries using the ThreeJS library. I want to apply a texture image over a hollow circle (basically, a ring built by the THREE.RingGeometry function) and obtain the results…
ggmendez
  • 601
  • 7
  • 18
2
votes
2 answers

Display ffmpeg frames on opgel texture

I am using Dranger tutorial01 (ffmpeg) to decode the video and get AVI frames. I want to use OpenGL to display the video. http://dranger.com/ffmpeg/tutorial01.html The main function is as follows: int main (int argc, char** argv) { // opengl…
naki
  • 77
  • 2
  • 10
2
votes
1 answer

Direct3D: Draw textured cube with single DrawIndexedPrimitives call. Possible?

I am trying to draw a textured cube using just 8 vertices and one DrawIndexedPrimitives call. Is this even possible? I am having problems with the UV co-ordinates. I am finding it impossible to come up with suitable UV values which will work for all…
Agnel Kurian
  • 57,975
  • 43
  • 146
  • 217
2
votes
3 answers

Color mapping a texture in opengl

I am displaying a texture that I want to manipulate without out affecting the image data. I want to be able to clamp the texel values so that anything below the lower value becomes 0, anything above the upper value becomes 0, and anything between is…
Dan Vogel
  • 3,858
  • 7
  • 41
  • 57
2
votes
1 answer

What is the use of creating texture having width and height equal to Zero?

If Opengl allows to create a texture of width = height = 0 then what is the use of specifying other parameters like Internal Format, Format etc. Secondly what is the use of such texture.
abhijit jagdale
  • 609
  • 2
  • 8
  • 21
2
votes
1 answer

opengl texture format for floating-point gpgpu

I wish to process an image using glsl. For instance - for each pixel, output its squared value: (r,g,b)-->(r^2,g^2,b^2). Then I want to read the result into cpu memory using glReadPixels. This should be simple. However, most glsl examples that I…
zuuz
  • 859
  • 1
  • 12
  • 23