Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > JAI, Korean Text and Windows UNICODE

Reply
Thread Tools

JAI, Korean Text and Windows UNICODE

 
 
Nicholas Pappas
Guest
Posts: n/a
 
      05-31-2004
Hello all.

I'm still having some trouble with getting Java work its way through
Korean directories and filenames. I was able to load the strings in
properly (using Cp1252 as the charset), and can print them out to a
JTextArea as they appear in the Konqueror (KDE) browser.
When working in Linux, the images still fail to load properly when I
attempt to do so with JAI. Is there something special I need to do with
JAI in order for it to recognize an alternate charset? I only have
problems when working with strings w/ Korean text in them -- if the
string has no Korean UNICODE, the image loads fine.
Below is the code I am using to load the images:

private Appearance createAppearance(String filename) {
Appearance appear = new Appearance();

RenderedImage img;

BufferedImage buffer = null;
try {
img = (RenderedImage)JAI.create("fileload", filename);
RenderedImageAdapter ria = new RenderedImageAdapter(img);
buffer = ria.getAsBufferedImage();

TextureLoader loader = new TextureLoader(buffer, Texture.RGB);
Texture2D texture = (Texture2D)loader.getTexture();

texture.setEnable(true);
texture.setMagFilter(Texture.NICEST);

appear.setTexture(texture);
} catch (IllegalArgumentException e) {
System.err.println("Failed to load texture: " + filename);
}

return appear;
}

I am currently using JDK 1.4.1 (Blackdown), so I need JAI to do this.
I haven't gotten JDK 1.5.0 to install correctly on Gentoo Linux, so I
can't test that out yet, since the images I am working with are BMPs.

Thanks for any help! It is much appreciated!
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
A Korean city and university to roll out Linux and other Open Source software. A Nice Cup of Tea NZ Computing 0 02-18-2006 05:35 AM
Korean dvds: Shiri and JSA Ed Kim DVD Video 5 03-06-2005 04:29 PM
Trouble with the encoding of os.getcwd() in Korean Windows Erik Bethke Python 7 02-09-2005 05:11 PM
Reading and Typing Korean =?Utf-8?B?SmVhbg==?= Microsoft Certification 2 11-30-2004 10:33 PM
ASP and Korean James Lattanzio ASP General 1 04-29-2004 12:25 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57