X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=pdf2swf%2Fswfoutput.cc;h=2161d9e3fed2e074857df4a99a4204a7030207d0;hb=602d0f0a1c8ad614029f235cc6ff38bfe26334e8;hp=75efd2c57b0dcecd11d6484850a29c6750827334;hpb=1f237fb411319057ae1e4f779e511cea0e206858;p=swftools.git diff --git a/pdf2swf/swfoutput.cc b/pdf2swf/swfoutput.cc index 75efd2c..2161d9e 100644 --- a/pdf2swf/swfoutput.cc +++ b/pdf2swf/swfoutput.cc @@ -646,7 +646,7 @@ SWFFont::~SWFFont() swflastx=0; swflasty=0; - swf_SetU8(ftag,0x10); //0 fill bits, 0 linestyle bits + swf_SetU8(ftag,0x10); //1 fill bits, 0 linestyle bits SHAPE s; s.bits.fill = 1; s.bits.line = 0; @@ -1343,23 +1343,28 @@ static void drawimage(struct swfoutput*obj, int bitid, int sizex,int sizey, if(y4>ymax) ymax=y4; if(x4linewidth,&obj->strokergb); //fsid = ShapeAddSolidFillStyle(shape,&obj->fillrgb); - fsid = swf_ShapeAddBitmapFillStyle(shape,&m,bitid,0); + fsid = swf_ShapeAddBitmapFillStyle(shape,&m,bitid,1); swf_SetU16(tag, myshapeid); r.xmin = (int)(xmin*20); r.ymin = (int)(ymin*20); @@ -1472,11 +1477,11 @@ int swfoutput_drawimagelossless(struct swfoutput*obj, RGBA*mem, int sizex,int si return bitid; } -int swfoutput_drawimagelossless256(struct swfoutput*obj, U8*mem, RGBA*pal, int sizex,int sizey, +int swfoutput_drawimagelosslessN(struct swfoutput*obj, U8*mem, RGBA*pal, int sizex,int sizey, double x1,double y1, double x2,double y2, double x3,double y3, - double x4,double y4) + double x4,double y4, int n) { TAG*oldtag; U8*mem2 = 0; @@ -1505,7 +1510,7 @@ int swfoutput_drawimagelossless256(struct swfoutput*obj, U8*mem, RGBA*pal, int s oldtag = tag; tag = swf_InsertTag(tag,ST_DEFINEBITSLOSSLESS2); swf_SetU16(tag, bitid); - if(swf_SetLosslessBitsIndexed(tag,sizex,sizey,mem, pal, 256)<0) { + if(swf_SetLosslessBitsIndexed(tag,sizex,sizey,mem, pal, n)<0) { swf_DeleteTag(tag); tag = oldtag; return -1;