我需要使用PHP将BMP转换为坐标图。
所以,
会变成,
15,9,19,9,19,9,25,10,25,10,28,10,28,10,32,10,32,10,35,10,35,10,35,10,25,10,25,13,25,13,25,16,25,16,25,18,25,18,23,20,23,20,22,23,22,23,21,25,21,25,20,28,20,28,20,28,9,31,14,29,14,29,17,28,17,28,22,28,22,28,25,27,25,27,28,27,28,27,32,28,32,28,35,29,35,29,35,29,46,11,46,13,46,13,46,17,46,17,46,23,46,23,46,25,46,25,46,27,46,27,45,29,45,29,44,31,44,31,44,31,47,12,47,15,47,15,48,18,48,18,53,26,53,26,53,28,53,28,55,32,55,32,56,35,56,35,57,32,57,32,57,30,57,30,57,28,57,28,57,26,57,26,57,24,57,24,57,22,57,22,57,20,57,20,57,17,57,17,57,15,57,15,57,13,57,13,57,11,57,11,57,11,68,12,68,14,68,14,68,18,68,18,68,23,68,23,68,28,68,28,68,32,68,32,67,34,67,34,67,34,70,12,74,12,74,12,77,12,77,12,80,12,80,12,84,14,84,14,88,16,88,16,88,18,88,18,88,20,88,20,88,22,88,22,87,24,87,24,85,26,85,26,83,28,83,28,80,30,80,30,76,32,76,32,73,32,73,32,69,33,69,33,69,33,98,15,98,18,98,18,98,20,98,20,98,23,98,23,98,26,98,26,98,28,98,28,98,30,98,30,98,32,98,32,98,32,98,15,102,15,102,15,105,15,105,15,108,15,108,15,111,15,111,15,114,15,114,15,114,
15,99,22,104,24,104,24,108,24,108,24,111,24,111,24,111,24,98,32,101,32,101,32,105,32,105,32,110,32,110,32,113,32,113,32,116,32,116,32,119,32,119,32,119,32,133,15,134,17,134,17,131,21,131,21,130,24,130,24,129,26,129,26,128,28,128,28,127,30,127,30,126,32,126,32,126,32,133,15,137,14,137,14,141,16,141,16,143,18,143,18,143,20,143,20,143,23,143,23,142,25,142,25,140,27,140,27,136,28,136,28,131,28,131,28,128,26,128,26,131,28,131,28,134,29,134,29,137,30,137,30,140,32,140,32,143,35,143,35,143,37,143,37,143,37,
前2个坐标是(15,9)和(19,9)。这是2个连接点。 PHP中是否有一个本机函数可以为我执行此操作,还是需要遍历图像的每个像素并自己构建此坐标图?
任何想法都会受到赞赏。
由于