You can subscribe to this list here.
| 2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(134) |
Sep
(52) |
Oct
(13) |
Nov
(342) |
Dec
(163) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2003 |
Jan
(44) |
Feb
(62) |
Mar
(158) |
Apr
(38) |
May
(70) |
Jun
(58) |
Jul
(104) |
Aug
(207) |
Sep
(83) |
Oct
(122) |
Nov
(23) |
Dec
(49) |
| 2004 |
Jan
(119) |
Feb
(132) |
Mar
(192) |
Apr
(140) |
May
(77) |
Jun
(74) |
Jul
(201) |
Aug
(63) |
Sep
(102) |
Oct
(70) |
Nov
(173) |
Dec
(78) |
| 2005 |
Jan
(174) |
Feb
(197) |
Mar
(105) |
Apr
(59) |
May
(77) |
Jun
(43) |
Jul
(21) |
Aug
(18) |
Sep
(47) |
Oct
(37) |
Nov
(74) |
Dec
(50) |
| 2006 |
Jan
(44) |
Feb
(19) |
Mar
(32) |
Apr
(24) |
May
(31) |
Jun
(55) |
Jul
(138) |
Aug
(28) |
Sep
(12) |
Oct
(41) |
Nov
(58) |
Dec
(24) |
| 2007 |
Jan
(28) |
Feb
(14) |
Mar
(10) |
Apr
(68) |
May
(30) |
Jun
(26) |
Jul
(18) |
Aug
(63) |
Sep
(19) |
Oct
(29) |
Nov
(20) |
Dec
(10) |
| 2008 |
Jan
(38) |
Feb
(7) |
Mar
(37) |
Apr
(120) |
May
(41) |
Jun
(36) |
Jul
(39) |
Aug
(24) |
Sep
(28) |
Oct
(30) |
Nov
(36) |
Dec
(75) |
| 2009 |
Jan
(46) |
Feb
(22) |
Mar
(50) |
Apr
(70) |
May
(134) |
Jun
(105) |
Jul
(75) |
Aug
(34) |
Sep
(38) |
Oct
(34) |
Nov
(19) |
Dec
(20) |
| 2010 |
Jan
(11) |
Feb
(20) |
Mar
(65) |
Apr
(83) |
May
(104) |
Jun
(73) |
Jul
(78) |
Aug
(57) |
Sep
(43) |
Oct
(35) |
Nov
(9) |
Dec
(4) |
| 2011 |
Jan
(21) |
Feb
(11) |
Mar
(18) |
Apr
(10) |
May
(18) |
Jun
(15) |
Jul
(48) |
Aug
(25) |
Sep
(17) |
Oct
(45) |
Nov
(15) |
Dec
(12) |
| 2012 |
Jan
(21) |
Feb
(9) |
Mar
(12) |
Apr
(9) |
May
(9) |
Jun
(5) |
Jul
(1) |
Aug
(10) |
Sep
(12) |
Oct
(1) |
Nov
(28) |
Dec
(5) |
| 2013 |
Jan
(4) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2014 |
Jan
|
Feb
(1) |
Mar
(1) |
Apr
|
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2015 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
|
Dec
|
| 2016 |
Jan
(2) |
Feb
(1) |
Mar
(1) |
Apr
(1) |
May
(2) |
Jun
|
Jul
(1) |
Aug
(2) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
|
|
|
1
(1) |
2
(1) |
|
3
(6) |
4
|
5
|
6
(2) |
7
|
8
|
9
|
|
10
|
11
(2) |
12
|
13
(1) |
14
|
15
(2) |
16
(4) |
|
17
(4) |
18
(3) |
19
|
20
|
21
|
22
(5) |
23
(14) |
|
24
(9) |
25
|
26
(2) |
27
(6) |
28
(5) |
29
(3) |
30
|
|
31
|
|
|
|
|
|
|
|
From: Elias N. <eli...@us...> - 2004-10-16 21:59:29
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/linux In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12813/src/native/linux Modified Files: org_lwjgl_input_Keyboard.c Log Message: Linux: Added basic support for Xutf8LookupString, providing better support for international characters Index: org_lwjgl_input_Keyboard.c =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/linux/org_lwjgl_input_Keyboard.c,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- org_lwjgl_input_Keyboard.c 15 Oct 2004 21:31:46 -0000 1.8 +++ org_lwjgl_input_Keyboard.c 16 Oct 2004 21:59:20 -0000 1.9 @@ -44,6 +44,8 @@ #include <X11/Xutil.h> #include <string.h> #include <assert.h> +#include <iconv.h> +#include <errno.h> #include "Window.h" #include "common_tools.h" #include "org_lwjgl_input_Keyboard.h" @@ -62,6 +64,11 @@ static bool translation_enabled; static bool created = false; +// X input manager values +static iconv_t iconv_descriptor; +static XIM xim = NULL; +static XIC xic = NULL; + static void grabKeyboard(void) { if (!keyboard_grabbed) { int result = XGrabKeyboard(getDisplay(), getCurrentWindow(), False, GrabModeAsync, GrabModeAsync, CurrentTime); @@ -87,6 +94,19 @@ } } +static void closeUnicodeStructs() { + if (iconv_descriptor != (iconv_t)-1) + iconv_close(iconv_descriptor); + if (xic != NULL) { + XDestroyIC(xic); + xic = NULL; + } + if (xim != NULL) { + XCloseIM(xim); + xim = NULL; + } +} + JNIEXPORT void JNICALL Java_org_lwjgl_input_Keyboard_nCreate (JNIEnv * env, jclass clazz) { @@ -122,11 +142,25 @@ buffer_enabled = false; initEventQueue(&event_queue, 3); updateKeyboardGrab(); + + // Allocate unicode structures + iconv_descriptor = iconv_open("UCS-2", "UTF-8"); + if (iconv_descriptor != (iconv_t)-1) { + xim = XOpenIM(getDisplay(), NULL, NULL, NULL); + if (xim != NULL) { + xic = XCreateIC(xim, XNClientWindow, getCurrentWindow(), XNFocusWindow, getCurrentWindow(), XNInputStyle, XIMPreeditNothing | XIMStatusNothing, NULL); + if (xic == NULL) { + closeUnicodeStructs(); + } + } else + closeUnicodeStructs(); + } } JNIEXPORT void JNICALL Java_org_lwjgl_input_Keyboard_nDestroy (JNIEnv * env, jclass clazz) { + closeUnicodeStructs(); ungrabKeyboard(); created = false; decDisplay(); @@ -143,9 +177,56 @@ putEvent(&event_queue, event_list); } -static void translateEvent(XKeyEvent *event, jint keycode, jint state) { +static int lookupStringISO88591(XKeyEvent *event, jint *translation_buffer) { static XComposeStatus status; - char temp_translation_buffer[KEYBOARD_BUFFER_SIZE]; + char char_translation_buffer[KEYBOARD_BUFFER_SIZE]; + int i; + + int num_chars = XLookupString(event, char_translation_buffer, KEYBOARD_BUFFER_SIZE*sizeof(char), NULL, &status); + for (i = 0; i < num_chars; i++) + translation_buffer[i] = ((jint)char_translation_buffer[i]) & 0xff; + return num_chars; +} + +static int lookupStringUnicode(XKeyEvent *event, jint *translation_buffer) { + char utf8_translation_buffer[KEYBOARD_BUFFER_SIZE]; + jchar ucs2_translation_buffer[KEYBOARD_BUFFER_SIZE]; + char *utf8_buf = utf8_translation_buffer; + jchar *ucs2_buf = ucs2_translation_buffer; + size_t ucs2_bytes = KEYBOARD_BUFFER_SIZE*sizeof(jchar); + Status status; + int i; + + XSetICFocus(xic); + size_t utf8_bytes = Xutf8LookupString(xic, event, utf8_translation_buffer, KEYBOARD_BUFFER_SIZE*sizeof(char), NULL, &status); + if (status != XLookupChars && status != XLookupBoth) + return 0; + XUnsetICFocus(xic); + // reset converter + iconv(iconv_descriptor, NULL, NULL, NULL, NULL); + // convert from UTF-8 to UCS-2 + size_t iconv_result = iconv(iconv_descriptor, &utf8_buf, &utf8_bytes, (void *)&ucs2_buf, &ucs2_bytes); + // compute number of characters converted + int num_chars_converted = KEYBOARD_BUFFER_SIZE - ucs2_bytes/sizeof(jchar); + if (iconv_result == (size_t)-1) { + errno = 0; // ignore conversion error and return no chars converted + return 0; + } + for (i = 0; i < num_chars_converted; i++) { + translation_buffer[i] = ((jint)ucs2_translation_buffer[i]) & 0xffff; + } + return num_chars_converted; +} + +static int lookupString(XKeyEvent *event, jint *translation_buffer) { + if (xic != NULL) { + return lookupStringUnicode(event, translation_buffer); + } else + return lookupStringISO88591(event, translation_buffer); +} + +static void translateEvent(XKeyEvent *event, jint keycode, jint state) { + jint temp_translation_buffer[KEYBOARD_BUFFER_SIZE]; int num_chars, i; jint ch; @@ -153,12 +234,12 @@ putKeyboardEvent(keycode, state, 0); return; } - num_chars = XLookupString(event, temp_translation_buffer, KEYBOARD_BUFFER_SIZE, NULL, &status); + num_chars = lookupString(event, temp_translation_buffer); if (num_chars > 0) { - ch = ((jint)temp_translation_buffer[0]) & 0xFF; + ch = temp_translation_buffer[0]; putKeyboardEvent(keycode, state, ch); for (i = 1; i < num_chars; i++) { - ch = ((jint)temp_translation_buffer[i]) & 0xFF; + ch = temp_translation_buffer[i]; putKeyboardEvent(0, 0, ch); } } else { |
|
From: Brian M. <ma...@us...> - 2004-10-16 01:02:50
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/test/fmod3 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23618/src/java/org/lwjgl/test/fmod3 Added Files: TagFieldTest.java Log Message: tagfields implemented --- NEW FILE: TagFieldTest.java --- /* * Copyright (c) 2002-2004 LWJGL Project * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are * met: * * * Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * * Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * * * Neither the name of 'LWJGL' nor the names of * its contributors may be used to endorse or promote products derived * from this software without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ package org.lwjgl.test.fmod3; import java.io.File; import java.io.IOException; import java.nio.IntBuffer; import org.lwjgl.BufferUtils; import org.lwjgl.fmod3.FMOD; import org.lwjgl.fmod3.FMODException; import org.lwjgl.fmod3.FSound; import org.lwjgl.fmod3.FSoundStream; import org.lwjgl.fmod3.FSoundTagField; /** * $Id: TagFieldTest.java,v 1.1 2004/10/16 01:02:34 matzon Exp $ <br> * * @author Brian Matzon <br...@ma...> * @version $Revision: 1.1 $ */ public class TagFieldTest { public static void main(String[] args) { if (args.length < 1) { System.out.println("Usage:\n TagFieldTest <file>"); // default to phero.mp3 args = new String[] { "res\\phero.mp3"}; System.out.println("Using default: " + args[0]); } File file = new File(args[0]); if (!file.exists()) { System.out.println("No such file: " + args[0]); return; } try { FMOD.create(); } catch (FMODException fmode) { fmode.printStackTrace(); return; } System.out.println("Initializing FMOD"); if (!FSound.FSOUND_Init(44100, 32, 0)) { System.out.println("Failed to initialize FMOD"); System.out.println("Error: " + FMOD.FMOD_ErrorString(FSound.FSOUND_GetError())); return; } System.out.println("Loading " + args[0]); FSoundStream stream = FSound.FSOUND_Stream_Open(args[0], FSound.FSOUND_NORMAL, 0, 0); if (stream != null) { //scratch buffer IntBuffer scratch = BufferUtils.createIntBuffer(16); FSound.FSOUND_Stream_Play(0, stream); // find number of tags FSound.FSOUND_Stream_GetNumTagFields(stream, scratch); int tagCount = scratch.get(0); System.out.println("Found: " + tagCount + " tag fields"); // print each name value pair FSoundTagField field; for(int i=0; i<tagCount; i++) { field = new FSoundTagField(); if(FSound.FSOUND_Stream_GetTagField(stream, i, field)) { System.out.println("Field " + i + ": " + field.getName() + ", " + field.getType() + ", " + field.getValueAsString() + ", " + field.getLength()); } } // trying to find the artist field System.out.println("Looking for tag..."); field = new FSoundTagField(FSound.FSOUND_TAGFIELD_ID3V1, "ARTIST"); if(FSound.FSOUND_Stream_FindTagField(stream, field)) { System.out.println("Found field: " + field.getName() + ", " + field.getType() + ", " + field.getValueAsString() + ", " + field.getLength()); } System.out.println("Press enter to stop playing"); try { System.in.read(); } catch (IOException ioe) { } System.out.println("Done playing. Cleaning up"); FSound.FSOUND_Stream_Stop(stream); FSound.FSOUND_Stream_Close(stream); } else { System.out.println("Unable to play: " + args[0]); System.out.println("Error: " + FMOD.FMOD_ErrorString(FSound.FSOUND_GetError())); } FSound.FSOUND_Close(); FMOD.destroy(); } } |
|
From: Brian M. <ma...@us...> - 2004-10-16 01:02:19
|
Update of /cvsroot/java-game-lib/LWJGL/src/native/common/fmod3 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23491 Modified Files: org_lwjgl_fmod3_FSound.c Log Message: tagfields implemented Index: org_lwjgl_fmod3_FSound.c =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/native/common/fmod3/org_lwjgl_fmod3_FSound.c,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- org_lwjgl_fmod3_FSound.c 10 Sep 2004 21:58:11 -0000 1.2 +++ org_lwjgl_fmod3_FSound.c 16 Oct 2004 01:02:10 -0000 1.3 @@ -1086,10 +1086,22 @@ * Method: nFSOUND_Stream_FindTagField * Signature: (JILjava/lang/String;Lorg/lwjgl/fmod_instance/FSoundTagField;)Z */ -JNIEXPORT jboolean JNICALL Java_org_lwjgl_fmod3_FSound_nFSOUND_1Stream_1FindTagField(JNIEnv * env, jclass clazz, jlong p1, jint p2, jstring p3, jobject p4) { - //XXX - throwFMODException(env, "missing implementation"); - return false; +JNIEXPORT jboolean JNICALL Java_org_lwjgl_fmod3_FSound_nFSOUND_1Stream_1FindTagField(JNIEnv * env, jclass clazz, jlong stream, jint type, jstring name, jobject tagField) { + const char * nName = (*env)->GetStringUTFChars(env, name, 0); + bool result = false; + void* value; + jint length; + + if(fmod_instance->FSOUND_Stream_FindTagField((FSOUND_STREAM*) stream, type, nName, &value, &length)) { + + // get set method and call it + jclass cls = (*env)->GetObjectClass(env, tagField); + jmethodID mid = (*env)->GetMethodID(env, cls, "set", "(Ljava/lang/String;Ljava/nio/ByteBuffer;I)V"); + (*env)->CallVoidMethod(env, tagField, mid, name, safeNewBuffer(env, value, length), type); + result = true; + } + (*env)->ReleaseStringUTFChars (env, name, nName); + return result; } /* @@ -1195,10 +1207,23 @@ * Method: nFSOUND_Stream_GetTagField * Signature: (JILorg/lwjgl/fmod_instance/FSoundTagField;)Z */ -JNIEXPORT jboolean JNICALL Java_org_lwjgl_fmod3_FSound_nFSOUND_1Stream_1GetTagField(JNIEnv * env, jclass clazz, jlong p1, jint p2, jobject p3) { - //XXX - throwFMODException(env, "missing implementation"); - return false; +JNIEXPORT jboolean JNICALL Java_org_lwjgl_fmod3_FSound_nFSOUND_1Stream_1GetTagField(JNIEnv * env, jclass clazz, jlong stream, jint num, jobject tagField) { + jint type; + char* name; + void* value; + jint length; + + if(fmod_instance->FSOUND_Stream_GetTagField((FSOUND_STREAM*) stream, num, &type, &name, &value, &length)) { + // create string instance of name + jstring nName = (*env)->NewStringUTF(env, name); + + // get set method and call it + jclass cls = (*env)->GetObjectClass(env, tagField); + jmethodID mid = (*env)->GetMethodID(env, cls, "set", "(Ljava/lang/String;Ljava/nio/ByteBuffer;I)V"); + (*env)->CallVoidMethod(env, tagField, mid, nName, safeNewBuffer(env, value, length), type); + return true; + } + return false; } /* |
|
From: Brian M. <ma...@us...> - 2004-10-16 01:01:28
|
Update of /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/fmod3 In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23265/src/java/org/lwjgl/fmod3 Modified Files: FSound.java FSoundTagField.java Log Message: tagfields implemented Index: FSound.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/fmod3/FSound.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- FSound.java 2 Oct 2004 21:06:23 -0000 1.11 +++ FSound.java 16 Oct 2004 01:01:10 -0000 1.12 @@ -2368,7 +2368,6 @@ * Get a tag field associated with an open stream * <p> * <b>Remarks</b> - * Do not attempt to modify or free any pointers returned by this function. * If this function returns successfully, "value" will contain a pointer to a piece of tag-field-specific data - do not assume it will always point to a null-terminated ASCII string. * @param stream The stream to get the tag field from. * @param num The number of the tag field to retrieve. Index: FSoundTagField.java =================================================================== RCS file: /cvsroot/java-game-lib/LWJGL/src/java/org/lwjgl/fmod3/FSoundTagField.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- FSoundTagField.java 12 Jun 2004 20:28:21 -0000 1.2 +++ FSoundTagField.java 16 Oct 2004 01:01:10 -0000 1.3 @@ -55,6 +55,12 @@ /** Type of tagfield */ int type; + + /** + * Creates a new FSoundTagField + */ + public FSoundTagField() { + } /** * Creates a new FSoundTagField @@ -65,36 +71,53 @@ } /** - * Sets the value and length + * Sets the name value and type + * @param name name of tagfield * @param value value of tagfield - * @param lenght length of data + * @param type type of tagfield */ - void set(ByteBuffer value, int lenght) { + void set(String name, ByteBuffer value, int type) { + this.name = name; this.value = value; - this.length = lenght; + this.length = value.capacity(); + this.type = type; } + /** * @return Returns the length. */ public int getLength() { return length; } + /** * @return Returns the name. */ public String getName() { return name; } + /** * @return Returns the type. */ public int getType() { return type; } + /** * @return Returns the value. */ public ByteBuffer getValue() { - return value; + return value.asReadOnlyBuffer(); } + + /** + * @value as string + */ + public String getValueAsString() { + byte[] buffer = new byte[value.capacity()]; + value.get(buffer); + value.rewind(); + return new String(buffer); + } } \ No newline at end of file |