Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » RichText,QTF,RTF... » Loading Image into qtf
Re: Loading Image into qtf [message #9918 is a reply to message #9913] Fri, 08 June 2007 15:58 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
try

dw.DrawImage(0, 0, img);

(You are drawing outside the area at 500, 500).

Or perhaps you really wanted

dw.DrawImage(0, 0, 500, 500, img)

- stretches the image to fill the area.

Anyway, that is still too ineffective, there is a nice function:

RichObject CreateImageObject(const Image& img, int cx = 0, int cy = 0);

which produces RichObject directly, without the need of ImageDraw.

For storing into DB, you can use what you suggest (which reperesents "internal" U++ image format), or you can use any StreamRasterEncoder and SaveString method.

See reference/ImageEncoders - just use SaveString to store to String instead of SaveFile (which stores to file).
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Rendering qtf into a window: horrible flicker
Next Topic: Failed to set String format in report from SQLite3
Goto Forum:
  


Current Time: Mon May 06 01:29:19 CEST 2024

Total time taken to generate the page: 0.02225 seconds