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 - EgonOlsen

Pages: 1 ... 793 794 [795] 796 797 ... 822
11911
Support / 3ds loader
« on: February 10, 2005, 09:04:55 pm »
The ql.3ds doesn't define diffuse colors for its materials, so it's to be expected if it shows up all white. I think that you are somehow not defining diffuse colors for your materials too (or the loader is buggy, but i never noticed anything like that). Try this file: http://www.jpct.net/download/Park.zip
Its materials are using diffuse color information only and it definitely loads and displays fine in your applet (i used it to test it).
I can only repeat myself: I can't really help you, if i don't have the model at hand that you are using.

11912
Support / 3ds loader
« on: February 10, 2005, 05:20:19 pm »
As mentioned: I can't really test it without the model that you are using. I compiled your code and loaded a 3ds of mine instead and it looked fine. I suggest to change the ambient lighting to
mWorld.setAmbientLight(155, 155, 155);
and to remove the additional light source that you are adding to mWorld.
What do you get then? Still everything white?
I'm also unable to notice any flickering in your applet. What is there is some tearing, because you can't synchronize the applet's drawing with the monitor's refresh, but that's ok.
jPCT doesn't care about frames or other components. All it does, is to render into an Image. You can do with this image whatever you want to. The draw(Graphics)-methods from FrameBuffer are just shortcuts to g.drawImage(...) calls. You don't have to use them...

11913
Support / 3ds loader
« on: February 10, 2005, 01:11:40 pm »
Can you send me a 3DS file that shows this problem, please?! If it says that materials have been added, it should work. If it doesn't, something is wrong either with your code or with my loader, but i can't verify it without an example.

TextureManager is a singleton. It will be created automatically if needed. You don't have to care about it.

11914
Support / 3ds loader
« on: February 10, 2005, 01:49:39 am »
IF your materials contain colors, jPCT should load them. Due to the nature of jPCT, it should create a unicolored texture for each of them. Have a look at the console output while loading the 3DS. Does it tell you that some textures have been added to the TextureManager? If it does, the colors are most likely loaded correctly.

11915
Support / 3ds loader
« on: February 10, 2005, 01:22:45 am »
The 3ds loader should import textures (which you are obviously not using) and material colors. It won't import anything else like transparency, shinyness etc.
3DS should be the format of choice in your case. Just keep in mind that jPCT's 3DS loader (or the engine itself) is not meant to be a complete 3DS-viewer. Some information of the 3DS will get lost on the way...
If you are still having problems, feel free to send your 3DS file to me, so that i can verify what exactly you are trying to display and how to do that in the best way possible,

11916
Projects / Technopolies
« on: February 09, 2005, 11:43:27 pm »
Every time you are posting a screen shot, i ask myself how this is possible with jPCT... :wink:
If you promote your game (and i'll do for sure too), this should be a winner...

11917
Support / Re: visible sides
« on: February 09, 2005, 11:33:46 pm »
Quote from: "raft"
first of all i must mention jpct really seems great :)
It is.... :wink:

11918
Support / visible sides
« on: February 09, 2005, 11:33:00 pm »
That's right...but you can set this value to anything your machine permits. Just do that before instanciating the World and you are fine.

11919
Support / 3ds loader
« on: February 09, 2005, 11:29:54 pm »
jPCT does load texture coords but it won't care for the names you gave to your (sub-)objects. They are loaded and named in the order that they have in the file. jPCT will query the TextureManager for textures named like the ones that you've added, if that's your question!?

11920
Support / Software reflections, projected shadows, etc.
« on: February 07, 2005, 05:56:05 pm »
Anfy3D is much much more low level and basic than jPCT is (there's no much support for anything else then pure polygon pushing). The version i have here shows no traces of support for shadows or mirrors (or at least i'm unable to find them), so i assume that they have "hacked" the engine to do it and that it's not a official feature that you just have to enable.
To answer your question: It it possible to add these things to jPCT, but i won't do it ATM. For mirrors, you should be able to do it yourself by rendering into another Framebuffer which you then use as a texture. It will slow down to a crawl in OpenGL, but should be possible in software mode. Shadows are difficult to add to jPCT's current pipeline...i once started working on that but stopped it after two days. It would require a major refractoring to make them work and that won't happen in this iteration of the engine, i'm afraid.

Edit: google for EgonOlsen and anfy3d to find out what i really think about anfy3d... :wink:

11921
Support / Rendering different cameras
« on: January 31, 2005, 08:13:31 am »
Quote from: "Melssj5"
Should I use a World for every applet instead from one static World on an unique class to handle all the objects????
Not necessarely...that would mean that you have to use multiple instances of your objects too, because an Object3D can only belong to one instance of World. But what you can't do, is render one World with multiple Cameras at a time. A World contains for example the VisList, which will be modified in the rendering. If you render one World in multiple threads, the results will be..whatever...even worse: If you switch to OpenGL one day (and away from an applet), your application will simply crash, because only one thread has the right context for rendering in hardware. So i suggest to do the rendering in one thread and one after the other. If that's not an option and you can for sure say that you'll never use OpenGL in your application, you may extend World and add a kind of locking, so that only one thread can do the rendering at a time and all others have to wait for it to finish.

11922
Support / Applet example 0.96
« on: January 30, 2005, 04:14:33 pm »
Forget about the timer-thread if there should be such thing in the code and replace it with a none-threaded timer approach like the newer examples (fps, car) are doing it.

11923
Support / Rendering different cameras
« on: January 30, 2005, 02:35:56 am »
I don't understand your problem. It's possible to assign a different Camera to a World to render the world from different views. Why doesn't that work for you? I can't see a difference between doing a setCameraTo(camera1)-render()-setCameraTo(camera2)-render and a render(camera1)-render(camera2)...  :?:

Edit: Or are you trying to render the same instance of World using different cams at exactly the same time using different threads? If that's the case...well, that won't work anyway. You have to make sure that the renders take place in a defined order one after the other.

11924
Projects / Re: jar compression
« on: January 29, 2005, 02:56:14 am »
Quote from: "rolz"
Helge,

I want to obfuscate applet classes for size reduction.
Could i do same with jpct libraries ?

 (170 kb technopolies.jar + 150 kb jpct.jar = 181kb technopolies.jar)

The license permits it. So if it works...no problem. However, i would double check on all VMs...sometimes, obfuscated code won't run on one VM or the other.

11925
Support / Java and OpenGL
« on: January 26, 2005, 07:12:47 pm »
Quote from: "DazedDude"
P.S Sorry about the non-relativity..Im new to programming  :oops:
No problem... :wink: If you are new to programming, i honestly wouldn't try to start with OpenGL or 3D graphics in general. Try to code something more simple first. If that's not an option, you may consider to use a 3D engine that does the low level work for you. jPCT is such an engine, just give it a try.

Pages: 1 ... 793 794 [795] 796 797 ... 822