토론:온라인행동
지각생 연습장
- http://latecomer.pe.kr/ribbon : 리본 제작 웹프로그램을 만드는 중
text2image 구현에 쓰일만한 php 함수들
- imageftbbox — Give the bounding box of a text using fonts via freetype2
- imagefttext — Write text to the image using fonts using FreeType 2
- imagepstext — Draws a text over an image using PostScript Type1 fonts
- imagettftext — Write text to the image using TrueType fonts
- imagestring — Draw a string horizontally
- imagestringup — Draw a string vertically
- imagechar — Draw a character horizontally
- imagecharup — Draw a character vertically
- imagestring 함수의 예제를 그대로 복사/붙여서 http://latecomer.pe.kr/ribbon/test2.php 를 만들었다. 폰트와 인코딩을 어떻게 조절하면 좋을까? 오늘은 일단 여기까지 --Latecomer 2008년 5월 31일 (토) 04:02 (KST)
- 폰트/인코딩 문제를 해결해서 한글 이미지를 만들고 : 트루타입 폰트를 업로드한후 imagettftext 함수의 인자로 지정해서 한글 이미지 표시 성공
- 색과 폰트, 위치/크기 등을 선택하는 인터페이스를 만들자
참고
- http://sir.co.kr/bbs/board.php?bo_table=pl_php&wr_id=370&page=7 : 재밌는 핵(hack)이긴 하지만 추천하고 싶진 않다. gd 라이브러리의 기본 함수만 이용해도 구현 가능하다.