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

Pages: 1 ... 4 5 [6] 7 8 ... 58
76
Support / Re: I can texture any primitive except a plane. Why?
« on: December 08, 2010, 01:32:00 pm »
The u/v coordinates for the primitives are not well defined (they are mainly for testing purposes).  I generally create my own primitives problematically and set the u/v coordinates the way I like them (particularly for planes and cubes).  Here is an example you might find useful:

Code: [Select]
        floor = new Object3D( 2 );
        float offset = scale;  // some float for sizing

        floor.addTriangle( new SimpleVector( -offset, -offset, 0 ),
                           0, 0,
                           new SimpleVector( -offset, offset, 0 ), 0, 1,
                           new SimpleVector( offset, offset, -0 ), 1, 1,
                           TextureManager.getInstance().getTextureID(
                                                             "expo_bumps" ) );
        floor.addTriangle( new SimpleVector( offset, offset, 0 ),
                           1, 1,
                           new SimpleVector( offset, -offset, 0 ), 1, 0,
                           new SimpleVector( -offset, -offset, 0 ), 0, 0,
                           TextureManager.getInstance().getTextureID(
                                                             "expo_bumps" ) );
This is the basic case that creates a 2-poly quad.  For more polys (such as a large terrain), you can put something similar to this inside a couple for loops and use the varriables to calculate "u" and "v" (float values between 0 - 1 representing positions on the texture for each vertice).

77
Projects / Re: 3D Sound System
« on: December 08, 2010, 02:42:03 am »
Yes, you can use the core SoundSystem with LibraryJavaSound plugin and any of the codec plugins for unsigned applets

78
Projects / Re: Archar
« on: December 05, 2010, 11:48:03 pm »
After some additional thought, I've decided to leave the engine in c++ code for now, and modify LWJGL's Applet Loader so it also deploys the native engine libraries along with all the other native libraries that it already has.  That way I can access the engine from the Java applet, without actually having it deployed as Java byte code.  Once I get the applet working at some point in the distant future, I'm planning to port the project to the Android which will also let me deploy the engine as a native library.

79
Projects / Re: 3D Sound System
« on: November 24, 2010, 03:56:50 am »
Are there any docs or tutorials for soundsystem jpct?

Yes I wrote a guide a while back with some example programs, called Guide to SoundSystemJPCT  (source for example programs)

80
Projects / Re: 3D Sound System
« on: November 23, 2010, 11:24:19 pm »
CodecJorbis, Bug-Fix

Jorbis codec pluggin

- Fixed a bug where certain types of .ogg files created in versions of Audacity were cut off just before the end of the sample.

81
Projects / Re: 3D Sound System
« on: October 24, 2010, 05:44:08 am »
Bug-Fixes Update

Sound System jPCT
Sound System

JavaSound library pluggin

WAV codec pluggin


What's New:
- Updated CodecWav link to current version
- Improved LibraryJavaSound performance slightly in non-Sun Java versions
- Handled rare pan-control exception
- Fixed fadeOutIn bug which caused fade-in effect to be silent

82
Projects / Re: Simple Animated Texture Interface
« on: October 23, 2010, 03:58:54 am »
Actually, looking back at the code, the applet already does both hardware and software mode (right-click to switch between the two).  The interface itself doesn't really care which rendering method jPCT is using.

There was a small bug related to this topic.  It manifested itself in software mode by misalignment and color problems (strangely, hardware mode didn't experience any problem even though the texture was not defined correctly).  I had solved the bug some time ago, but I never got around to updating this project.  I've recompiled and tested it, and everything seems to be working now, in case anyone is copying the code in their own projects.

83
Projects / Re: Archar
« on: October 22, 2010, 11:55:51 pm »
Speaking of Java, that brings me to an important question.  I have started porting the engine from c++ to Java, firstly because jPCT is Java, but secondly because that is the most likely environment it will ultimately be running on in future projects as well.  My question is about preventing people from stealing the engine for use in their own projects.  Despite the fact that my recent projects have all been free and open source, I am not one of those anti-intellectual-property zealots.  I would like to maintain sole control of the technology, at least for now.  My initial thought is to hide interfaces to the engine in internal private classes and methods.  Does anyone know how secure this is?  How difficult is it to partially reverse-engineer Java byte-code to access internal methods?  The program would not have to be completely reverse-engineered - merely changing the interfaces from private to public would give someone the ability to utilize the engine in any project.

I suppose if I was completely paranoid, I could interface with the engine via a Perl script server-side, and have the applet communicate with it over a secure encrypted connection.  Of course, that would be a lot more work, and perhaps a bit of overkill.

84
Support / Re: Info on calcAngle on SimpleVector
« on: October 22, 2010, 11:37:08 pm »
That looks like it should work.  I came up with another way to do something similar to this (a single-axis billboarding effect I needed to add glow effects to cylindrical objects).  In case you run into any issues with your formula, I can give you another way to do the same thing.

85
Projects / Re: Archar
« on: October 22, 2010, 11:24:19 pm »
Not sure, but I think Leap Frog would be a pretty good place to start researching, though.  Their products are starting to become pretty advanced.  I recently bought a toy dog called "Scout"  for my son.  It has a USB port to allow customization like programming the child's name, favorite things, songs, etc.  And their hand-held devices are also pretty advanced.

86
Projects / Re: Archar
« on: October 22, 2010, 10:57:17 pm »
Were you planning on using it for games eventually, or something else?
My ultimate goal is to put it into a toy which children could have a real conversation with.  The idea first came to me after being utterly disappointed with a toy called Furbie back in Christmas of 1998.  There was a huge hype about how kids could teach it to talk and have real conversations with it.  This turned out to be a total crock of ****.  In reality it was merely capable of fake learning - i.e. it learned exactly the same things at exactly the same time regardless of what the kid playing with it said or did.  He could be talking in Japanese, and the damn thing would still "learn" English.  I vowed to one day make a toy that could ACTUALLY learn to talk by listening to the child..

In the mean time, I want to use it in a few projects to get people interacting with it and hopefully address any problems before trying to pitch the technology to a toy company at some point in the future.

87
Projects / Re: Simple Animated Texture Interface
« on: October 22, 2010, 10:45:30 pm »
I'll put together a software-mode only version.  Note that while this texture effect approach is easier to use and will work in any case, it is best suited for effects which require too many frames to fit into a single texture (videos, etc).   The "mosaic texture" idea which I used in my Animated Textures project (placing everything onto a single texture and changing the u/v coordinates to animate), while a little less wieldy, performs faster for effects with fewer frames (such as most GIF animations).  Ultimately, it just depends on the particular project I suppose.

88
Projects / Archar
« on: October 22, 2010, 02:55:05 am »
Background

I have been playing around with an AI concept for years (one of several "cool idea" projects I'm working on).  It is a text-based contextual learning engine which is capable of picking up grammatical sentence structures very quickly, and using that information to generate random grammatically-correct sentences in response to input sentences.  The context of the sentences it produces is randomly related to the words contained in the input sentence (so if a user types a sentence about cats, the engine might respond with a sentence about cats, animals, fur, etc).  I've decided the engine has reached a high enough level of stability that I can start using it in projects.


Project Concept

Archar (an acronym for Artificial Character) will be my first project utilizing the engine.  It will be an applet consisting of a 3D character which you can talk to through the microphone and it will talk back to you through the speakers.  I will accomplish this through speech recognition to convert what the user says into text, and then speech synthesis to convert the engine's output into audio.  This audio will need to be synced with the facial animations of the head.  jPCT is perfect for the 3D applet piece, and I've written some synchronization methods into my sound system which should be useful for this project as well.

89
Support / Re: health bar
« on: October 22, 2010, 12:39:06 am »
Another couple options if blitting doesn't work for you, if it is just a 2-color bar you could make a texture twice the width of the bar with the health color on the left half and the no-health color on the right.  Then just change the u/v coordinates to the right to lose health and to the left to gain health.  For more complicated graphics I would use frames tiled on a single "mosaic" texture and switch the uv coordinates as necessary (see my GIF texture project for an example).  This is what I'm doing for the HUD and shield strength pannels for the game I'm working on.  If you need help figuring out the uv switching code or setting up the texture let me know.

90
Support / Re: Info on calcAngle on SimpleVector
« on: October 21, 2010, 11:31:35 pm »
360 degrees doesn't make sense when you consider the fact that the two vectors can be any orientation.  There are always going to be two arcs you can measure angles for (and if you know one you know the other since they add to 360 degrees).  How would you specify which arc is the one you want to measure?  That's a question which depends on each particular project.  You have to take the information jPCT gives you and decide which arc you are looking for.  I can probably help with this if you let me know what you are after (I've used this extensively in the auto navigation system I wrote for the game I'm working on).

Pages: 1 ... 4 5 [6] 7 8 ... 58