Save Graphic scene in Database
i have a qgraphic scene and a picture in Graphicview
The picture provide in Pixmap for Graphicview
and with scene user can draw line on picture
but i want save and Retrieve image and drawing Lines in SqlServer Database
What i must Do ?
this show to save load image to db
for the lines, u need to store x1,y1,x2,y2 and maybe color etc.
but this save lines has been drawn in scene ?
or jsut save the pic?
just image unless you change the actual image but
if you use the normal line object, you must handle that besides the images.
(as its not part of the image)
can you help me how i can save that normal lines?
well , is that not just 4 ints/floats ?
for start x,y and end x,y ?
You need to save color or anything else?
to get the points.
i think its better to capture screenshot from that pic and lines
how can i capture screenshot from x,y location?
ok, if that is what u wish.
The lines will no be lines then , when u load it again.
they will be part of image
Everything u need for screen capture is here
i saw this example
but this capture all of screen!
i want to capture Particular points!
How should i do this?
the core is
originalPixmap = screen->grabWindow(0);¨
so you can grab any widget or window this way.
If you need only a subset of widget, then grab whole widget
and cut the pixmap to the wanted size using
This post is deleted!
Thanks a lot Brother :)
My Problem Solved!