Hi all,
I'm trying to wrap my head around the OpenGL object model on iPhone OS. I'm currently rendering into a few different UIViews (build on CAEAGLayers) on the screen. I currently have each of these as using separate EAGLContext, each of which has a color renderbuffer and a framebuffer.
I'm rendering similar things in them, and I'd l...
Hello,
I'm new to opengl-es and I wonder how people are able to draw these much detailed OpenGL ES graphics, e.g. on Android OS. It's already hard to draw a single squre, because it's composed of triangles due to the reason that OpenGL ES obviously cannot draw anything else than triangles.
I thought about this approach:
Drawing and ren...
What is the good resource to learn OpenGL ES (2.0) for someone who didn't have exposure to OpenGL or any other graphics API before?
Note that I'm not interested at phone programming. My main goal is to gather some experience and knowledge of basic concepts which I could latter apply to phones, desktop gaming, WebGL or whatever, without ...
I'm trying to modify the fragment shader which is part of the standard iPhone/XCode OpenGL ES template. I want to make it so that every other row of pixels is transparent. I have this code so far:
varying lowp vec4 colorVarying;
void main()
{
gl_FragColor = vec4(colorVarying.x, colorVarying.y, colorVarying.z, floor(mod(gl_FragCoord...
Hi everyone !
I know the following question have been asked many times on different forums, but after viewing different solutions, it still did not fix my problem, or maybe I did not get what they mean
I am trying to model a pyramid using OpenGL ES 2.0 on the iPhone.
I would like to allow the user to rotate this pyramid using the touch ...
I have more than 1000 of tiles size 256 each.
This is actually a large image cut in tiles.
I need to show in android OpenGL.
The problem is I cannot load more than 7x7 = 49 tiles.
Thanks
saiful
...
Hi there. I have created a grid with 40 x 40 vertex3D (small but useful)
I can pick a single vertex out of that grid by simply calling a function with the position array[X][Y], And therefore neighbors too. How can I raise up neighbor vertex Z value so they kinda look like a bubble or sphere kind of thingy?
My first tough was to use:
N...
Is there a way to use CATransform3D, or similar, to twist a UIView? What I mean is to rotate the top edge of the view, but keep the bottom edge where it is. All the transformations I've looked at keep the view 'flat'. Is this more of an Open GL task?
...
Hi,
I am trying to make an OpenGLES 2.0 cube application.
The idea was to have a texture (with an alpha 75%) applied to all 6 faces of the cube.
This would mean that even if I rotate the cube i would be able to see all 6 faces at any given frame. Now I have enabled depth test(my app needs this!!) and blending. The Depth func is LEQUAL a...
I'm checking out the nightly builds of Firefox and Chromium with support of WebGL with a few demos and tutorials and I can't help but wonder about the extremely high CPU load they cause.
A simple demo like this one runs at a sustained 60% of my dual core. The large version of this one maxes out the CPU to 100% and has some visible frame...
Hey there,
Recently I ran into a very strange issue: touching the screen of the iPhone and moving a finger around can eat up to 50% of my FPS. Yeah, I checked my code for possible bottlenecks – not the issue. The last resort I tried before writing this post – commenting out all the touch processing code and looking at FPS then. Results ...
I know it's possible to repeat an entire texture by setting the wrap mode to GL_REPEAT, but is it somehow possible to repeat only a subregion of the texture? For example, when the texture is part of an atlas.
I'm targetting OpenGL ES 1.x, so shaders are out.
...
XCode's OpenGL template seems to be cheating to solve this "stretched" viewport problem I've been trying to understand for the last 3 hours.
In the iphone "OpenGL ES Application" template, the colorful square that bounces up and down on the screen is not really a square at all!
ES1Renderer.m (the ES2 file as well)
static const GLflo...
What am I doing wrong here, I can't get the result of this division:
aspectRatio = backingWidth / backingHeight;
I've thought I might try casting to (GLfloat) but that didn't do anything. As I step through the code I see that aspectRatio is 0 after the operation, while backingWidth is clearly 768 and backingHeight is 1029.
Here are ...
Hi,
I am new to Android development and have an assignment to read frame buffer data after a specified interval of time.
I have come up with the following code:
public class mainActivity extends Activity
{
Bitmap mSavedBM;
private EGL10 egl;
private EGLDisplay display;
private EGLConfig config;
private EGLSurface s...
Let's see if I can explain myself.
When you set up the glFrustrum view it will give the perspective effect. Near things near & big... far things far & small. Everything looks like it shrinks along it's Z axis to create this effect.
Is there a way to make it NOT shrink that much?
To approach perspective view to an orthographic view.... ...
Hi all,
I have my app on iPhone with a UIViewController with some stuff inside.. image, textbox, etc...
is there a way to draw a line or something like this using opengl directly inside the UIViewController?
thanks in advance
...
I am trying to convert my app to use a navigation controller. It uses the EAGLView from the Xcode GL ES startup project to render its graphics. I am trying to add it to the navigation controller hierarchy. The EAGLView is currently constructed by the nib, so the first thing I do is remove it from the window so it doesn't appear twice. Wh...
I have an array of GLuint with fixed size:
GLuint textures[10];
Now I need to set a size of array dynamically. I wrote something like this:
*.h:
GLuint *textures;
*.m:
textures = malloc(N * sizeof(GLuint));
where N - needed size.
Then it used like this:
glGenTextures(N, &textures[0]);
// load texture from image
-(GLuint)ge...
Hello,
I would like to draw a image on the screen where ever the user touches.
I can't figure out how to do it.
Please help
thank you!
...