Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Thomas.

Pages: 1 2 [3] 4 5 6
31
Bugs / Static uniforms
« on: August 11, 2012, 07:18:14 pm »
Static uniforms is not sent to shader after application is restored. What differences are among static and "classic" uniforms?

32
Bugs / Shader isn't copied
« on: July 29, 2012, 02:12:16 pm »
By constructor Object3D(Object3D obj, boolean reuseMesh) is not copied shader too.

33
Support / modelViewProjectionMatrix
« on: July 20, 2012, 11:11:34 am »
How can I get modelViewProjectionMatrix in code? Is there some getter for this?

34
Support / Help camera, overlay
« on: July 10, 2012, 09:38:28 pm »
What is the fastest way to "clone" camera? I need same camera position, direction, FOV, everything in two world.
How is working object in overlay? Render to target horizontal flips texture, I fix it, but... it isn't ideal solution...

Code: [Select]
plane.setCulling(false);
plane.setRotationPivot(new SimpleVector(0, 0, 10));
plane.rotateX((float) Math.PI);
plane.translate(0, 0, -8);

35
Support / Fragment shader - color by position
« on: July 08, 2012, 09:35:45 pm »
Is possible to get color in fragment shader from current image buffer by position? I can't find any info about it on the internet...

36
Support / Depth buffer texture
« on: June 30, 2012, 01:58:21 am »
What is the best solution for render zbuffer? shader is not problem, but if I have screen resolution 1280*720, do I need texture resolution 2048*1024? I don't know how exactly working GPU with texture, but when I understand correctly power of 2 is needed for mip-mapping?

edit: and what is the best way to implement depth of field? I need three rendering, normal, zbuffer and plane, but how this does intelligently? :D

37
Support / uniform and nullPointerException
« on: June 21, 2012, 12:17:35 pm »
When I call shader.setUniform("lightDirection", new SimpleVector(0, 0, 1)); I'll get this error, any idea where is problem?

Code: [Select]
06-21 12:10:37.432: E/AndroidRuntime(16226): FATAL EXCEPTION: GLThread 2166
06-21 12:10:37.432: E/AndroidRuntime(16226): java.lang.RuntimeException: [ 1340273437379 ] - ERROR: java.lang.NullPointerException
06-21 12:10:37.432: E/AndroidRuntime(16226): at com.threed.jpct.GLSLShader.update(GLSLShader.java:561)
06-21 12:10:37.432: E/AndroidRuntime(16226): at com.threed.jpct.GL20.updateShaderData(GL20.java:215)
06-21 12:10:37.432: E/AndroidRuntime(16226): at com.threed.jpct.GLRenderer.initShader(GLRenderer.java:519)
06-21 12:10:37.432: E/AndroidRuntime(16226): at com.threed.jpct.CompiledInstance.render(CompiledInstance.java:431)
06-21 12:10:37.432: E/AndroidRuntime(16226): at com.threed.jpct.GLRenderer.drawVertexArray(GLRenderer.java:2211)
06-21 12:10:37.432: E/AndroidRuntime(16226): at com.threed.jpct.World.draw(World.java:1319)
06-21 12:10:37.432: E/AndroidRuntime(16226): at com.threed.jpct.World.draw(World.java:1081)
06-21 12:10:37.432: E/AndroidRuntime(16226): at cz.chladek.mygame.AppActivity$MyRenderer.onDrawFrame(AppActivity.java:555)
06-21 12:10:37.432: E/AndroidRuntime(16226): at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1463)
06-21 12:10:37.432: E/AndroidRuntime(16226): at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1217)
06-21 12:10:37.432: E/AndroidRuntime(16226): at com.threed.jpct.Logger.log(Logger.java:189)
06-21 12:10:37.432: E/AndroidRuntime(16226): at com.threed.jpct.Logger.log(Logger.java:148)
06-21 12:10:37.432: E/AndroidRuntime(16226): at cz.chladek.mygame.AppActivity$MyRenderer.onDrawFrame(AppActivity.java:625)
06-21 12:10:37.432: E/AndroidRuntime(16226): at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1463)
06-21 12:10:37.432: E/AndroidRuntime(16226): at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1217)

And could you add method setUniform(String name, SimpleVector[] vals)? Thanks

38
Support / Light type attribute
« on: June 15, 2012, 04:35:07 pm »
Please, could you add attribute for type of light, that will be sent to shader? Something like this...

Code: [Select]
uniform lowp int lightTypes[8];
For me is impossible to solve this problem in another way...

I wrote per-pixel spotlight, but I can't use point light and spotlight together...



edit: oh, and of course it's needs next attribute like light direction, spot cut off and spot exp... so maybe add some user variable?

39
Support / Load normals from file
« on: June 13, 2012, 06:55:25 pm »
Egon, please, could you add support for load normals from OBJ file? For compatibility you can add "Config.loadNormalsFromOBJ = false;" ... Thanks, in return I offer model for your game :) ... and it would be nice if you also add possibility for object without normals, maybe method "Object3D.build(boolean containsNormals);"

40
Support / Vertex color
« on: June 06, 2012, 09:37:20 pm »
How can I set color of vertices?

41
Support / disabled culling and normals in shader
« on: May 25, 2012, 01:35:03 pm »
I have problem with objects without culling. I'm using shader for calculating per-pixel lighting. When I disable culling, normals are still same, so lighting is "bad" from other side. Is there any simple and fast solution? or is better to use two triangle for each side?

42
Bones / smooth player movements
« on: May 19, 2012, 01:26:04 pm »
I'm new in bones... what is the best way for smooth player movements? Probably, I need to do model of player and his skeleton in 3Ds max and export with OgreMax. Is possible to moving individually bones by code in application? Is this good and fast way? If yes, is there any example?

43
Bones / minimal library
« on: May 17, 2012, 08:43:18 pm »
Is there any minimal library, that contains all what is needed? 2.35MB isn't good...

44
Support / add triangle with normal
« on: April 14, 2012, 10:11:41 pm »
Please, could you add method for set normals? Something like this:

Code: [Select]
addTriangle(SimpleVector vert1, SimpleVector norm1,  float u,  float v,
      SimpleVector vert2, SimpleVector norm2, float u2, float v2,
      SimpleVector vert3, SimpleVector norm3, float u3,  float v3);

45
Bugs / Memory and replace texture
« on: April 14, 2012, 06:05:37 pm »
When I use Texture.replaceTexture() method, original is probably still in memory. Can someone confirm it?

I have textures 512*512 and when is all replace by 128*128 memory increased to 42MB, before it was 35MB

Pages: 1 2 [3] 4 5 6