- if (x==0)
- { b = swf_CountBits(y,2);
- if(b<2)
- b=2;
- if(b-2 >= 16) {
- fprintf(stderr, "Bit overflow in swf_ShapeSetLine(2)- %d (%d)\n", b, y);
- b = 17;
+ if(x!=0 && y!=0) { //(!s)||((x!=0)&&(y!=0)))
+ swf_SetBits(t,3,2); // Straight Edge
+ swf_SetBits(t, b-2, 4); //Number of Bits in x/y
+ swf_SetBits(t,1,1); // Diagonal
+ swf_SetBits(t,x,b);
+ swf_SetBits(t,y,b);
+ } else if (x==0) {
+ swf_SetBits(t,3,2); // Straight Edge
+ swf_SetBits(t, b-2, 4); //Number of Bits in y
+ swf_SetBits(t,1,2); // Vertical
+ swf_SetBits(t,y,b);
+ } else {
+ swf_SetBits(t,3,2); // Straight Edge
+ swf_SetBits(t, b-2, 4); //Number of Bits in x
+ swf_SetBits(t,0,2); // Horizontal
+ swf_SetBits(t,x,b);