P
Pritcham
Hi all
I hope someone here can help me. Basically I'm trying to use bitblt on
a picture that's being shown (using the excellent Picturebox class from
Stephen Lebans site) on my Access form.
What I'm trying to achieve is this: I've successfuly loaded the
picturebox with the graphics I want, I've been able to plot on top of
this image but it's working out to be a little too slow due to the
number of plots I'm having to do. In light of that I'm looking at an
alternative - namely combining two/three images into one (like layering
them ontop of each other)
After doing some Googling it appears that using a call to the BitBlt
API function may be what I need but this is where I'm getting stuck.
I've tried numerous calls to the API but all I get is a blank box where
the 'combined' picture should be, so either I'm not calling the API
right or something else is going amiss - any help would really be
appreciated.
Code snippet is below (Where pb2 is the destination, and pb1 is the
already initialised source):
Set pb2 = New clsPictureBox
pb2.ImageControl = Me.img2
pb2.ImageForm = Me
pb2.Clear
BitBlt pb2.hdc&, 0&, 0&, pb.dib_width, pb.dib_height, pb.hdc&, 0, 0,
SRCCOPY
One thing I've come across a number of times is to set the "ScaleMode"
for both source and destination as PIXELS but I can't see this property
anywhere in order to set it
Any help appreciated.
Thanks in advance
Martin
I hope someone here can help me. Basically I'm trying to use bitblt on
a picture that's being shown (using the excellent Picturebox class from
Stephen Lebans site) on my Access form.
What I'm trying to achieve is this: I've successfuly loaded the
picturebox with the graphics I want, I've been able to plot on top of
this image but it's working out to be a little too slow due to the
number of plots I'm having to do. In light of that I'm looking at an
alternative - namely combining two/three images into one (like layering
them ontop of each other)
After doing some Googling it appears that using a call to the BitBlt
API function may be what I need but this is where I'm getting stuck.
I've tried numerous calls to the API but all I get is a blank box where
the 'combined' picture should be, so either I'm not calling the API
right or something else is going amiss - any help would really be
appreciated.
Code snippet is below (Where pb2 is the destination, and pb1 is the
already initialised source):
Set pb2 = New clsPictureBox
pb2.ImageControl = Me.img2
pb2.ImageForm = Me
pb2.Clear
BitBlt pb2.hdc&, 0&, 0&, pb.dib_width, pb.dib_height, pb.hdc&, 0, 0,
SRCCOPY
One thing I've come across a number of times is to set the "ScaleMode"
for both source and destination as PIXELS but I can't see this property
anywhere in order to set it
Any help appreciated.
Thanks in advance
Martin