We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
Page Index Toggle Pages: 1
greek text (Read 1359 times)
greek text
Dec 11th, 2009, 6:45pm
 
hello, i have no idea on how to view greek text using the text() function. Processing just does not recognize it. In case of: text("sth in greek+sth in english",50,50) or print("sth in greek+sth in english") the only thing i get is the english part. In fact the real problem is that if i try to make a vlw file after checking the all characters box (in order for the greek characters to be converted) i get a memory error after processing using over 100% of my cpu. The set limit is of my ram memory is at 2048 mb. Does anybody has a vlw file with greek characters or knows another way to solve the problem? I have an imac at 2.16 / 3gb so this is not the problem or at least i think so. thanksssss!!!
Re: greek text
Reply #1 - Dec 11th, 2009, 6:57pm
 
did you search for "greek" i did
http://processing.org/discourse/yabb2/num_1163019721.html

maybe that works for you
Re: greek text
Reply #2 - Dec 11th, 2009, 7:35pm
 
i did too but i dont have a vlw font, i keep geting the same error / except i understood something wrong
Re: greek text
Reply #3 - Dec 11th, 2009, 7:49pm
 
works fine, when i use this sketch...

PFont f;

void setup() {
 f = createFont("ArialMT",22);
}

void draw() {
 background(0);
 textFont(f,22);  
 text("\u03A8\u03B5\u03C3!", 10, 20);
}


i get some weird greek symbols
Re: greek text
Reply #4 - Dec 12th, 2009, 2:19am
 
See problem - unicode string in P2D and P3D mode.
Exporting a whole font with lot of characters is a bad idea, you have to select the characters of interest or use a specialized font.
Re: greek text
Reply #5 - Dec 12th, 2009, 4:21am
 
cendric this was really helpful, is this font greek only? It works for me but how do i use a different one? PhiLho, how can i select only the letters i want? I do not think that i could do it with processing. I will see later what is your link about.
Re: greek text
Reply #6 - Dec 14th, 2009, 10:15am
 
it just does not work with the p3D renderer but you already know this and i can not understand much from the link Philho posted. trebani's example only works for hangul but i am sure it can work for me too after an improovment or two.
Re: greek text
Reply #7 - Dec 15th, 2009, 3:34am
 
Yes, it isn't so hard. You just have to find a font with Greek chars (lot of fonts have it), localize the ranges of interest for you (a tool like BabelMap is precious here) and adapt the constants to your needs.
Re: greek text
Reply #8 - Dec 15th, 2009, 6:01am
 
you were write! thank you very much for your time + help.
Page Index Toggle Pages: 1