Hi, I am creating a simple opengl application which obviously includes some 3d-objects and textures. My problem is however that artifacts appear on every texture. These come in the form of triangles along the edges.
I have noticed that it disappears as soon as I move the view-point closer to texture it renders perfectly. Therefore I ha...
I have one texture that has some portions which are transparent transparent I want to apply over an object whose faces are some opaque material (or colour if it's simpler) but the final object gets transparent. I want the final object to be totally opaque.
Here is my code:
First I set the material:
glDisable(GL_COLOR_MATERIAL);
...
I've been interested (as a hobbyist) in pseudo-random noise generation, specifically the Perlin and Simplex algorithms. The advantage to Simplex is speed (especially at higher dimensions), but Perlin can be tiled relatively easily. I was wondering if anyone was aware of a tiling simplex algorithm? Fixed-dimension is fine, generic is bett...
I would like to increase the brightness on a texture used in OpenGL rendering. Such as making it bright red or white. This is a 2D rendering environment, where every sprite is mapped as a texture to an OpenGL polygon.
I know little to nothing on manipulating data, and my engine works with a texture cache, so altering the whole surface wo...
I am trying to do some Image processing on a UIImage using some EAGLView code from the GLImageProcessing sample from Apple. The sample code is configured to perform processing to a pre-installed image (Image.png). I am trying to modify the code so that it will accept a UIImage (or at least CGImage data) of my choice and process that inst...
The manual just instructed you to write:
glDeleteTextures(1, &GLtexture);
and claims that the texture will be deleted. iPhone has scarce memory and I want to ensure that these textures are truly released.
The Leaks instrument cannot detect this, and frankly, I am a bit worried. I do really want to make sure that the textures are rea...
Hi guys
Just started learning OpenGL and couldn't find a decent tutorial to get me going. Specifically, I'm looking for something that will show me how to load an image to an OpenGL texture, store it in a variable to display later, and then draw the image.
I'd appreciate it if someone could write out the basic code to do that for me. I...
I'm using OpenGL ES to display some objects exported from Blender. Blender provides a list of vertices, a list of the face indices and a list of the 2d texture co-ordinates. Within Blender, and I believe generally in OpenGL, the texture co-ordinates map to each vertex described in the index array.
I suppose I have two questions:
I...
Ok, so I'm trying to weigh up the pro's and con's of using various different texture compression techniques. I spend 99.999% of my time coding 2D sprite games for Windows machines using DirectX.
So far I have looked at texture packing (SpriteSheets) with alpha-trimming and that seems like a decent way to get a bit more performance. Now ...
I´ve got problems with opening textures in SDL. I´ve got a function to read bmp files, optimize them and add colorkey:
SDL_Surface* SDLStuff::LoadImage( char* FileName ) {
printf( "Loading texture: \"%s\"\n", FileName );
SDL_Surface* loadedImage = 0;
SDL_Surface* optimizedImage = 0;
loadedImage = SDL_LoadBMP( FileName );
optimizedImag...
I know mixing OpenGL and DirectX is not recommended but I'm trying to build a bridge between two different applications that use separate graphics API:s and I'm hoping there is a technique for sharing data, specifically textures.
I have a texture that is created in Direct3D like this:
d3_device-> CreateTexture(width, height,
1, D3DUS...
UPDATE:
I've posted the Renderer code below, since this code here doesn't seem to be the problem.
I'm having a problem with some code of mine where when I try to upload multiple textures to openGL, one at a time, it fails somewhat spectacularly, with the renderer only ending up using a single texture. I've done a bit of debugging to ...
I need to draw the background for a 2D space scrolling shooter. I need to implement 3 layers of stars: one distant nebula (moving really slow) in the background, one layer of far away stars (moving slow) and one layer of close stars (moving normal) on top of the other two.
The way i first tried this was using 3 textures of 320 x 480 tha...
I'm attempting to implement this paper. I've have most of it down, but the part about sending arbitrary, non-geometric data to the shader for use in determining and displaying geometric edges is causing me problems. I've managed to successfully send most of my data just fine using what I know of VBOs. However, I need to send a large amou...
I have a really weird problem with PVR textures on the iPhone simulator- the framerate falls through the floor on the iPhone simulator, but on the iPhone itself it works just fine. Has anyone had any experiences similar to this? I'm using SDK 3.1.2
...
Hello. I'm using the standard .fbx importer with custom shaders in XNA. The .fbx model is UV wrapped properly and is textured appropriately when I use BasicEffect. However when I use my custom effect I have to load the texture in as a parameter, and it is not mapped correctly.
Questions: 1) How can I texture my .fbx model properly usin...
I'm trying to draw grayscale image in color as texture in OpenGL using two colors. Black goes to color1 and white goes to color2. Texture is loaded using GL_RGBA.
I have tried two solutions:
1)
Load image as texture
Draw image on screen
Enable blending
glBlendFunc(GL_ONE_MINUS_DST_COLOR, GL_ZERO); and draw rectangle with color1
glBle...
In my 2D game I need textures that may be arbitrarily large, can be NPOT and nonsquare.
They are only ever mapped to one kind of primitive: rectangles via GL_QUADS (the four QUAD corners are mapped to the four texture corners). Sometimes the texture matrix has been scaled before drawing.
I want my game to work everywhere, even on old/ch...
How would I link in or compile SOIL (http://lonesock.net/soil.html) into my C++ OpenGL project on Mac OS X?
...
Due to performance issues, I have had to transfer my android opengl code from Java to C. I believe I transfered all of the OpenGL code, but I now have many errors with the section of my code that draws a bitmap as a texture to the screen.
When I run the project in an emulator, the current code does not display anything and appears to h...