Java-Gaming.org Hi !
Featured games (90)
games approved by the League of Dukes
Games in Showcase (731)
Games in Android Showcase (217)
games submitted by our members
Games in WIP (798)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1] 2 3 ... 16
1  Game Development / Newbie & Debugging Questions / Re: STB Font library with chinese characters on: 2017-06-21 19:35:42
I will look into it, Thanks Spasi Smiley
2  Game Development / Newbie & Debugging Questions / Re: STB Font library with chinese characters on: 2017-06-21 18:50:43
An idea I had was to create a sort of "wrapper", where I create a font object and attach charsets to it. Each charset defines a min, max, material, and stb-backed image. So, I can attach multiple font textures to a single font object, and mix the letters while drawing.

End result:


I am not sure if this is the best way to go about it though...
3  Game Development / Newbie & Debugging Questions / Re: STB Font library with chinese characters on: 2017-06-21 18:09:06
Well If I create a 4k texture I can populate it with what seems like most Simplified Chinese Characters spanning from the unicode range: 19850 - 41000

Looks like this:


However, then I can't fit punctuation because Chinese punctuation is stored in the 60000's (even though it looks just like English punctuation)
4  Game Development / Newbie & Debugging Questions / STB Font library with chinese characters on: 2017-06-21 14:54:44
Been playing around with this... But I am not getting anywhere. The most obvious problem is that I wont have a large enough texture... Chinese isn't written like english, where you have 26 letters and from that can construct any word; each word has its own Character. So if I were to write:
你好啊,今天吃饭了吗?昨天老师给我们贴别多的作业!我很晚去睡觉哈哈。
All of these characters have their own respective meaning. But since it isn't a letter-based system there are THOUSANDS of characters to choose from; i.e. how can I fit them all onto a texture?

The second problem I run into, which is where this is an issue with the STB library. The chinese characters stored in unicode are ALL OVER THE PLACE. Which is annoying because with STB you just declare a start and an end, and it fills the middle in with letters. But I need to define a lot of ranges spanning thousands of numbers to store them. I am not quite sure what to do.
5  Discussions / Miscellaneous Topics / Re: What I did today on: 2017-06-20 00:50:18
Made one of those soft particle things... Not sure if it's "technically" correct or not, but it looks pretty Smiley



Click to Play
6  Game Development / Shared Code / Re: Compute view/proj matrices for head tracking rendering on: 2017-06-14 14:23:35
Any sick videos to show it off? Tongue
7  Discussions / Miscellaneous Topics / Re: What I did today on: 2017-06-14 01:46:52
Programmed in grenades today:
Click to Play
8  Game Development / Newbie & Debugging Questions / Re: LWJGL3 OpenAL seems to cut off the end of sounds on: 2017-06-12 03:58:34
I am using the library that comes with Lwjgl3, STB. As such, I'm using the STBVorbis classes to load an ogg audio buffer into my game.

Here is the buffer creation code (It is not my own):
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
16  
17  
18  
19  
20  
21  
22  
23  
private ShortBuffer readVorbis(String resource, int bufferSize, STBVorbisInfo info) throws Exception {
    try (MemoryStack stack = MemoryStack.stackPush()) {
        vorbis = IOUtil.ioResourceToByteBuffer(resource, bufferSize);
        IntBuffer error = stack.mallocInt(1);
        long decoder = stb_vorbis_open_memory(vorbis, error, null);
        if (decoder == NULL) {
            throw new RuntimeException("Failed to open Ogg Vorbis file. Error: " + error.get(0));
        }

        stb_vorbis_get_info(decoder, info);

        int channels = info.channels();

        int lengthSamples = stb_vorbis_stream_length_in_samples(decoder);

        pcm = MemoryUtil.memAllocShort(lengthSamples);

        pcm.limit(stb_vorbis_get_samples_short_interleaved(decoder, channels, pcm) * channels);
        stb_vorbis_close(decoder);

        return pcm;
    }
}
9  Game Development / Newbie & Debugging Questions / LWJGL3 OpenAL seems to cut off the end of sounds on: 2017-06-12 02:00:57
Hello.

I've noticed that the last second (there abouts) of any audio clip gets cut-off when I play it in my game. To play the sound I am using: alSourcePlay(id);

The "quick-fix" is obviously to add some sound-less noise to the end of the clip. But this is just a workaround. Any ideas?
10  Game Development / Newbie & Debugging Questions / Re: Should I find another 3d physics library? on: 2017-06-12 01:56:08
I'll give it a try Smiley Thanks Ecumene.
11  Game Development / Newbie & Debugging Questions / Should I find another 3d physics library? on: 2017-06-09 18:48:52
I've been using JBullet in my engine for quite awhile now and It's always seemed to have a few issues with me. The main issue is that smaller objects seem to fall right through the ground almost always.
Here's a gif
Click to Play


The main problem here is that this should not be happening. The game is running the physics at 120 tps.

I feel like 120 tps should be fast enough to get rid of these kinds of issues. Obviously I know that with any physics engine if a body is going too fast it will go right through an object, but this speed with 120 tps doesn't feel right...
12  Game Development / Newbie & Debugging Questions / Re: OpenGL Coordinate system names on: 2017-06-08 01:37:43
abcdef, I'm well aware of the functionality of everything I described. I've been doing graphics programming (albeit self taught) for quite awhile now. I was just looking for definitions out of curiosity!

Thanks for the explanation, Kai Smiley Was exactly what I was looking for.
13  Game Development / Newbie & Debugging Questions / OpenGL Coordinate system names on: 2017-06-07 17:36:20
Quick question about the proper terminology with regards to OpenGL Coordinate System names

I know that a system whose limits are [0, 1] is named Device Coordinates
A system whose limits are [-1, 1] is named Normalized Device Coordinates
A system whose limits are based on the view matrix is named View Space
A system whose limits are based on the world matrix is named World Space

If this is correct so far, what about a system with a limit of [0, screen size] is named what? What would be called Screen space?

Is there a resource on this? I enjoy learning this proper terminology.
14  Discussions / Miscellaneous Topics / Re: What I did today on: 2017-06-02 00:50:20
Playing around with some of the lighting.

15  Discussions / Miscellaneous Topics / Re: What I did today on: 2017-06-01 02:58:42
Started the networking part
16  Discussions / Miscellaneous Topics / Re: What I did today on: 2017-05-31 14:58:15
Started making a little random room generator:

17  Discussions / Miscellaneous Topics / Re: What I did today on: 2017-05-25 02:54:30
If I had a dollar for every-time I saw that skybox...  Roll Eyes
18  Discussions / Miscellaneous Topics / Re: What I did today on: 2017-05-22 19:06:26
Been tweaking my SSR a little bit today:



The second image was inspired by a post I saw a few years ago from some SSR thread.
19  Game Development / Game Mechanics / Re: laggy camera movement on: 2017-05-05 18:07:17
Are you using lwjgl3 or lwjgl2?

If you are using lwjgl2, there was a bugged version which reading the polled mouse position would lag. I told Spasi about this a few months (a year?) ago and he fixed it.
20  Java Game APIs & Engines / OpenGL Development / Re: GlBegin gives lag. on: 2017-04-17 22:36:28
You can start by not using glBegin  Tongue Tongue I estimate a 200% speed increase.

Look into VBOs
21  Game Development / Shared Code / Re: All-Integral Alpha Compositing Using Bitwise Operators - Also New to JGO! on: 2017-04-08 17:24:29
I almost did a double take when I saw BlueJay...

Haven't seen that software in a long time!
22  Games Center / WIP games, tools & toy projects / Re: Kami - Java 3D voxel platformer on: 2017-04-04 16:51:27
On this version I only get about 30 fps. Quite a bit lower than the previous build Sad
23  Discussions / Miscellaneous Topics / Re: What I did today on: 2017-03-29 23:55:10
Finally getting around to implementing assimp.




Any help would be welcome, I can't seem to find any lwjgl resources involving assimp. All of the CPP resources are incompatible.
24  Games Center / WIP games, tools & toy projects / Re: Kami - Java 3D voxel platformer on: 2017-03-29 14:18:49
Very cool  Grin

I get a solid 50-60 fps.

Would be neat to see a PS1 styled game made with this. Something like Bugs Bunny: Lost in time Pointing Pointing
25  Discussions / Miscellaneous Topics / Re: What I did today on: 2017-03-29 14:15:09
@Apo
That pixel art is delicious.
26  Games Center / WIP games, tools & toy projects / Re: Kami - Java 3D voxel platformer on: 2017-03-28 15:13:05
Looks pretty cool! Smiley

Could you supply a jar to quickly test with?
27  Discussions / Miscellaneous Topics / Re: What I did today on: 2017-03-27 22:26:27
Started implementing player physics into my engine today Smiley

Works much better than the built-in bullet character object

Also tweaked the lighting:



28  Discussions / General Discussions / Re: [LWJGL] Which library is best for GUI and how do I change menus? on: 2017-03-25 16:08:04
Could always give Nuklear a try.
29  Game Development / Newbie & Debugging Questions / Re: Check which thread is calling a static method on: 2017-03-24 04:19:57
Ah perfect. Thanks! Smiley
30  Game Development / Newbie & Debugging Questions / Check which thread is calling a static method on: 2017-03-24 04:08:14
In my engine, I have a static method that can be called from two different threads.

I would like for a way to know which thread is calling the method. I want to change the method slightly depending on the thread, but would like to still just use 1 method.

Any thoughts would be appreciated!

For example:
1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
12  
13  
14  
15  
// Thread 1
a();

// Thread 2
a();

static void a() {
   if ( getThread() == THREAD_1 ) {
      // Do stuff
   } else {
      // Do other stuff
   }

   // Do even more stuff
}
Pages: [1] 2 3 ... 16
 
Archive (336 views)
2017-04-27 17:45:51

buddyBro (534 views)
2017-04-05 03:38:00

CopyableCougar4 (977 views)
2017-03-24 15:39:42

theagentd (1012 views)
2017-03-24 15:32:08

Rule (992 views)
2017-03-19 12:43:22

Rule (972 views)
2017-03-19 12:42:17

Rule (971 views)
2017-03-19 12:36:21

theagentd (1069 views)
2017-03-16 05:07:07

theagentd (990 views)
2017-03-15 22:37:06

theagentd (759 views)
2017-03-15 22:32:18
List of Learning Resources
by elect
2017-03-13 14:05:44

List of Learning Resources
by elect
2017-03-13 14:04:45

SF/X Libraries
by philfrei
2017-03-02 08:45:19

SF/X Libraries
by philfrei
2017-03-02 08:44:05

SF/X Libraries
by SkyAphid
2017-03-02 06:38:56

SF/X Libraries
by SkyAphid
2017-03-02 06:38:32

SF/X Libraries
by SkyAphid
2017-03-02 06:38:05

SF/X Libraries
by SkyAphid
2017-03-02 06:37:51
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!