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.


Messages - Varanda

Pages: [1] 2
1
Support / Re: Hello World - Demo
« on: March 30, 2018, 03:46:01 pm »
Thanks Egon,

It crashes in different places each time I run. If I process step by step in debugging it runs fine sometimes. It is like a thread is using something that it is not ready yet.

Once it crashed here:



03-30 13:16:28.290 4119-4140/? W/jPCT-AE: [ 1522415788290 ] - WARNING: State: 0/0/0/0/0/0/0
03-30 13:16:28.300 4119-4140/? E/AndroidRuntime: FATAL EXCEPTION: GLThread 1210
                                                 Process: com.marcelo.a3demo01, PID: 4119
                                                 java.lang.ArrayIndexOutOfBoundsException: length=0; index=0
                                                     at com.threed.jpct.CompiledInstance._fill(CompiledInstance.java:1226)
                                                     at com.threed.jpct.CompiledInstance.fill(CompiledInstance.java:847)
                                                     at com.threed.jpct.Object3DCompiler.compile(Object3DCompiler.java:168)
                                                     at com.threed.jpct.World.compile(World.java:2109)
                                                     at com.threed.jpct.World.renderScene(World.java:1067)
                                                     at com.marcelo.a3demo01.MainActivity.onDrawFrame(MainActivity.java:108)
                                                     at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1571)
                                                     at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1270)
03-30 13:16:28.407 4119-4141/? D/EGL_emulation: eglMakeCurrent: 0xa3f47c40: ver 2 0 (tinfo 0xa3f0b1b0)


    @Override
    public void onDrawFrame(GL10 gl10) {
        fb.clear();
        world.renderScene(fb); // this is the line 108
        world.draw(fb);
        fb.display();
    }


2
Support / Hello World - Demo
« on: March 27, 2018, 02:34:37 pm »
Hello All,

I am teaching Android UI development at a college in Canada and I would like to provide a very simplified demo of JPCL. It is not part of the curriculum but I thought that would be nice demo.

The idea was inspired on Prof. Giovanni Malnati  video:
https://youtu.be/6SLz7tMBA8k

However, I am having a hard time to make my demo to work. The App crashes while creating a framebuffer object. I tried GL ver 1 and a couple of other things and did not help. Following is the link for my App; in case someone would have some time to help would be great.

https://drive.google.com/open?id=1rAW3ybhmK9lNBX7wTG3dZ1bhu_2L-SWI


Thanks in advance,
Marcelo Varanda

3
Projects / Open Source Game: MulaKong
« on: April 13, 2016, 03:45:04 pm »
Hello All,

I have made MulaKong OpenSource as I had to slowdown my work hours for its development.
I believe that the logic is 1/3 done (as per my initial design) and Art the main models are completed. However, in my TODO list are:  Improve texture for the building, create surrounding buildings, streets, trees, sand beach, pick a better background (or SkyBox). Game is simple: prevent the Gorilla to reach the top of the building by shooting fruits. The first person is inside an helicopter (still missing a cockpit overlay) and flies around shooting the Kong. If he falls on the street than the player wins that phase.

Here is a demo recorded using the latest code:
https://youtu.be/SZL-d2at0vI

Code and art are already available in GitHub. License is GPL v3. Link:

https://github.com/mvaranda/MulaKong

Have fun,
Varanda

4
Bones / Re: Overlaping bones Animation
« on: March 30, 2016, 01:11:22 pm »
Thanks a lot, I will take a look at that helper.

5
I am using Blender exporter for both scene and bones for the last few days. Bones addon (Ogre) is a bit tricky to use. Trace dump sometimes brings wrong information (unless you really debug the root cause).

Here some tips:

- Even for meshes with Materials without file textures you need to unwrapp and add an image as texture. Make sure you load the image in UV Editor (only in material/texture property tab is not enough).
- Make sure that you do not have any mesh in edit mode when running the exporter. Otherwise, the exporter crashes.
- MOST IMPORTANT OF ALL: Always give a destination folder other than your project root. The first thing that the exporter does in to delete the destination directory (entire content). I lost my entire project when I run the exporter first time. JUST IN CASE MAKE A BACKUP before using this exporter.

6
Bones / Overlaping bones Animation
« on: March 29, 2016, 03:30:55 am »
Hello,

I have many individual animations working fine for my character. However, I would like to have smoother transitions. Is there an way to crossover the animations (weight ramps for in/out) ? I also have an independent head animation and I would like to play in combination with other bone animation sequences.

In case Bones Library provides this feature I would appreciate someone to point me out a demo code for it.

Thanks in advance,
Varanda

7
Support / Re: Texture with Alpha from Blender
« on: March 25, 2016, 11:42:11 pm »
Solution for now (override transparency after loading scene):
Code: [Select]
Enumeration<Object3D> objs = world.getObjects();
Object3D obj;
while (objs.hasMoreElements()) {
obj = objs.nextElement();
obj.setTransparency(-1);
}

A couple tips for those willing to use jpct Blender exporter addon:

- Even for meshes with Materials without file textures you need to unwrapp and add an image as texture. Make sure you load the image in UV Editor (only in material/texture property tab is not enough).
- Make sure that you do not have any mesh in edit mode when running the exporter. Otherwise, the exporter crashes.
- MOST IMPORTANT OF ALL: Always give a destination folder other than your project root. The first thing that the exporter does in to delete the destination directory (entire content). I lost my entire project when I run the exporter first time. JUST IN CASE MAKE A BACKUP before using this exporter.

Despite the problem I got so far this exporter and JPCt integration is VERY HANDY.

8
Support / Re: Texture with Alpha from Blender
« on: March 25, 2016, 12:56:13 am »
Something else is going on. The base of the building is an independent mesh. It does not have transparency settings. However, it shows transparent. The pictures above (first post) had already the following settings:


9
Support / Re: Texture with Alpha from Blender
« on: March 24, 2016, 05:09:26 pm »
Thanks. I will make the building 100% opaque and cut off the geometry and so making the "glasses" 100% transparent.

10
Support / Re: Texture with Alpha from Blender
« on: March 24, 2016, 03:37:03 pm »
I have the texture with mixed opaque and transparent areas applied the the same mesh (building).
Interesting that seems to be working as the areas with alpha=0 are indeed 100% transparent. The opaque (alpha = 1) seem to be rendered with an alpha <100%.

anyways, thanks a lot, I will try the suggested transparency set to -1 tonight.

11
Support / Texture with Alpha from Blender
« on: March 23, 2016, 02:37:05 am »
Hello All,

I am having some problems with a texture with some transparent areas. The building model have its balconies with a glass fence. It seems to work fine. However, the opaque regions where alpha are 1 are also transparent. My scene is created based on Blender Importer project (JPCTBlendScene). Has anyone experienced similar issue?

Left side: rendered in Blender, Right side: Rendered in JPCt on Nexus 7





Settings:




 
Thanks,
Varanda


12
Support / Re: samples under latest Android Studio
« on: March 13, 2016, 04:29:53 pm »
Not sure yet how AS pick the libs. Anyways, my 1440 faces animated model shows as 60fps. 5 instances still good as 41fps on a 3 year old Nexus 7.

https://youtu.be/sfV0Si7Mzww



BTW... is it worthy to trim the animation using curves or jPCT will interpolate keys disregarding Blender's curves?


13
Support / Re: samples under latest Android Studio
« on: March 12, 2016, 02:07:28 am »
Finally I have that BonesDemo project working with the latest AS.

Maybe the major change was issuing "./grablew clean" and got lost of updates which may have fixed that exception.

In case anyone needs it:
https://www.dropbox.com/s/6n9dchnlaz2fue7/BonesDemo.zip?dl=0

About the Bones-Android-Ninja I followed similar workflow but it seems that there is a Lib mismatch. Light is not implemented so I replaces the dependency to jpct_ae.jar; Then other mismatches show up like constructor for FrameBuffer take anymore a sampling mode etc.

I will try tomorrow as that Bones-Android-Ninja project seems to have tones of demos in it.

Varanda

------------------------
Update on Bones-Android-Ninja attempt:

After following similar workflow that worked for BonesDemo, for Bones-Android-Ninja I get missing "import com.threed.jpct" in CollisionTestActivity.java

So I added compile files('../bones/lib/jpct-1.26.jar')

After adding jpct I get:

/Users/mvaranda/cglabs_svn/trunk/jpct-ae/examples/Bones-Android-Ninja1/bonesAndroidNinja/src/main/java/bones/samples/android/CollisionTestActivity.java
Error:(27, 23) error: cannot find symbol class Light
Error:(125, 7) error: cannot find symbol class Light
Error:(176, 34) error: incompatible types: GL10 cannot be converted to int
Error:(186, 22) error: cannot access Image
class file for java.awt.Image not found
Error:(249, 15) error: no suitable method found for display(no arguments)
method FrameBuffer.display(Graphics) is not applicable
(actual and formal argument lists differ in length)
method FrameBuffer.display(Graphics,int) is not applicable
(actual and formal argument lists differ in length)
method FrameBuffer.display(Graphics,int,int) is not applicable
(actual and formal argument lists differ in length)
...
...
...

Looks like a lib version mismatch.

Here is my Bones-Android-Ninja:
https://www.dropbox.com/s/m7jij2x8fnbgp3j/Bones-Android-Ninja.zip?dl=0






14
Support / Re: samples under latest Android Studio
« on: March 11, 2016, 04:49:34 pm »
Thanks. I tried starting with a clean prj and bring java and libs one by one and making the adjustments. However, I keep getting:

Error:Execution failed for task ':app:mergeDebugResources'.
> java.lang.ArrayIndexOutOfBoundsException (no error message)

Which does not provide a meaningful clue (at least for me) where the problem is located.

Anyways... I will retry tonight or tomorrow morning. If you can zip and send to ma, even if it does not work, at least I can check the diff about the changes you have done.

my email: cglabs@mail.com (mail, not gmail).

Thanks a lot,
Varanda

15
Support / Re: samples under latest Android Studio
« on: March 11, 2016, 04:13:47 pm »
Thanks a lot, I will try that tonight.
Your support is amazing... that motivates me (and people) to stick with this jPCT.

Cheers,
Varanda

Pages: [1] 2