U++ framework
Do not panic. Ask here before giving up.

Home » U++ Library support » Draw, Display, Images, Bitmaps, Icons » Decrease PDF size. Compress images?
Re: Decrease PDF size. Compress images? [message #49439 is a reply to message #49438] Fri, 09 February 2018 20:06 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 14291
Registered: November 2005
Ultimate Member
PdfDraw JPEG support committed, example:

#include <CtrlLib/CtrlLib.h>
#include <Report/Report.h>
#include <PdfDraw/PdfDraw.h>

using namespace Upp;

GUI_APP_MAIN
{
	PdfDraw w;

	DrawJPEG(w, 100, 100, 2000, 1333, LoadDataFile("hermes.jpg"));
	
	String pdf = GetHomeDirFile("test.pdf");
	SaveFile(pdf, w.Finish());

	LaunchWebBrowser(pdf);
}


(reference/PdfDrawJPEG)

Note that it is necessary to have plugin/jpg in the project.
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: Loses qualifiers const in Size Image::GetDPI(void)
Next Topic: What is the best way to handle scaling icons?
Goto Forum:
  


Current Time: Sat Sep 12 05:15:05 GMT+2 2026

Total time taken to generate the page: 0.00578 seconds