all groups > dotnet drawing api > june 2004
Filter by week: 1 2 3 4 5
Picture comparison
Posted by Eduard Faschang at 6/30/2004 3:06:43 PM
Hallo
I am looking for an example . I want compare two image (digital photo).
If on the second picture a differnt too the first one - a operator get a
error message .
So mybe anyone have in c# a good example to solve this problem
Thank you
Edi
... more >>
Active X Mouse Events
Posted by Mark Richardson at 6/29/2004 9:47:01 PM
Hello,
I am using an axWebBrowser Active X control, and also a FlashObject Active X control. I am using VB.Net for my project. My question is this. None of the Active X controls have a mousedown, mouseup, mouseenter, etc event handlers. Is there a way that I can add these event handlers to the co... more >>
Creating an explosion or fire affect
Posted by John Wright at 6/29/2004 2:44:46 PM
I am trying to create an explosion and/or fire affect in VB.NET. Does
anyone have code or a link to help me out with this. Thanks.
John
... more >>
Multiple Transparent Controls
Posted by Chadd Nervig at 6/29/2004 2:35:01 PM
Hi all,
I'm making a graphical work surface where the user can move objects around on it, and am running into some problems which are making me despise .NET's 'psudo'-transparency.
What I want to happen: There are multiple non-rectangular controls on the worksurface that are drawn from scratch i... more >>
.NET Drawing Unit Measurements
Posted by henrycortezwu NO[at]SPAM hotmail.com at 6/29/2004 11:23:53 AM
Hi, I'm a bit confused unit measurements on VB .net
If one places a "Debug.WriteLine(Me.CreateGraphics.PageUnit)" on the
Load Event of a form, the result will be "Display", and if one places
a "Debug.WriteLine(e.Graphics.PageUnit)" on the Paint Event of a form,
the result will be "Pixels"
S... more >>
Image.FromFile Not Releasing Files
Posted by Ethan Adams at 6/29/2004 10:40:50 AM
I have developed a web application which does something along the following
lines:
string filePath = "C:\somfile.jpg";
using(System.Drawing.Image myImage =
System.Drawing.Image.FromFile(filePath))
{
Response.Clear();
myImage.Save(Response.OutputStream,
System.Drawing.Imaging.ImageF... more >>
DataGrid key press question
Posted by james_morris1232000 NO[at]SPAM yahoo.com.au at 6/28/2004 9:57:03 PM
1. up/down arrow keys to move up/down one recored at a time
2. Page Up/Down keys to move up/down one page at a time
3. CTRL+End and CTRL+Home keys to move to end and beginning(last
record and first record) of the datagrid respectively
code for page down:
public class Myform : System.Windo... more >>
how to get the pixelformat
Posted by Jeff Schumann at 6/28/2004 11:17:12 AM
I am trying to return the pixelformat of an image that I loaded. I keep on
receiving the error message "Object reference not set to an instance of an
object." on the last line. I'm not sure what I'm doing wrong. The code is
below.
Dim i As System.Drawing.Image
i.FromFile("e:\graphics\ima... more >>
Don't see what you're looking for? Search DevelopmentNow.com.
JPEG image outofmemory
Posted by juklingos NO[at]SPAM yahoo.com at 6/27/2004 1:50:47 PM
Hi all,
I load 16 jpeg images of 7Kb each one in my form but when i run my
application (pocket pc 2003) sometime I get outofmemory. I checked the
all memory allocated for my application and is almost 20Mb. I read
that even if the image is a compressed format like jpeg it can take up
to 1Mb in... more >>
Halo text effect with GDI+
Posted by Paul Selormey at 6/26/2004 8:22:59 AM
Hello,
Any help on rendering halo text effects with GDI+?
Best regards,
Paul.
... more >>
can add system.drawing to project?!
Posted by Alexandre at 6/25/2004 3:38:01 PM
I cant add any reference to the project;
i did;
tool -> add reference -> /net framework -> double lick on system.drawings
then type imports system.drawings
but it doesnt work. the reference is never added.
What am I doing wrong here?
Thanks!... more >>
Landscape Duplex is upside down
Posted by Mike Dekarske at 6/25/2004 11:31:55 AM
I can't find the property in printdocument.defaultpagesettings to change the
binding edge.
My duplex works fine but the back side of the page is upside down.
PrintDoc.DefaultPageSettings.Landscape = True
PrintDoc.PrinterSettings.Duplex = Duplex.Horizontal
I've also tried:
PrintDoc.Defa... more >>
Create region from image
Posted by Marc Selis at 6/25/2004 10:43:00 AM
Is there a simple way to create a region from an image that has a
transparent background?
The only way I have come up with is looping through all pixels and adding
those that are not transparent.
Does anybody have a better solution?
Thanks,
Marc Selis
... more >>
Bitmap to DIB? Example please...
Posted by NikolayUnguzov at 6/25/2004 10:21:30 AM
I have to convert Bitmap (dot NET Bitmap) to DIB (Device Independent
Bitmap). Can some one show me an example how to do this? NET Framework
doesn't have any conversion functionality from Bitmap to DIB... I want to
convert Bitmap to DIB in byte[] array (and later pass this to non dot NET
componen... more >>
Printed output is shifted to the right 1/4"
Posted by Eric Guthmann at 6/25/2004 12:12:59 AM
I'm trying to print using the .NET PrintDocument control, but the output is
always shifted to the right by about 1/4 inch. Does anyone have any idea
why this might be? The output is the same on my HP OfficeJet 7130 and HP
LaserJet 4L.
I'm able to reproduce this even using the following code:... more >>
manual drawpath
Posted by rr at 6/24/2004 3:00:25 PM
I have a Calculated the path of a bitmap into the GraphicPaths object. I
want to manually draw this path in a plotter fashion without using the
drawpath object. What is the best way of doing this...
Thanks,
RB
... more >>
HasMorePages does not get to the Next Page
Posted by Mike Dekarske at 6/24/2004 2:37:11 PM
I am doing a drawstring with the text contents of a text box. The text box
contains a string with embedded formfeeds. I'm finding the form feeds and
puting out the text up until the form feed. Then setting HasMorePages to
true.
When I send the next part of the string, it overlays the first ... more >>
drawing mask
Posted by mphanke at 6/24/2004 9:39:41 AM
Hi,
I have an icon which I want to draw as a black mask on a white bitmap.
How can I do this?
Martin... more >>
Region.IsVisible woes
Posted by Max Bolingbroke at 6/24/2004 7:41:45 AM
Hi
I create a graphics path like so:
GraphicsPath affectedPath = new GraphicsPath();
affectedPath.AddLine(startPoint, endPoint);
And then add it to a region:
affectedRegion.Union(affectedPath);
But now when I try to use IsVisible to see if a point lies on that line,
it will ALWAYS ... more >>
Code generation for property failed
Posted by Glenn Chittenden Jr. at 6/23/2004 10:27:12 AM
Hello,
I'm working on a component written with C#. The component contains a
property of type Image and loads a default image from its resource when an
instance is created.
When I add the component to a Form, the property grid shows the default
image, but when I save the form I get an error... more >>
Ways to improve GDI+ graphics layout?
Posted by kjon at 6/22/2004 10:48:59 PM
Hi,
Would like to know how can I use SmoothingMode, PixelOffsetMode and
TextContrast to improve the outcome of the GDI+ graphics (or other settings
I don't know)?
Basically I just want the GDI+ graphics to look better without affecting the
performance (speed, resources).
What is the best/o... more >>
REPOST - Alpha blending and GDI+/GDI interop
Posted by Brock Reeve at 6/22/2004 4:39:09 PM
Sorry about the repost. We are nearing release and would really like an
answer on this issue:
I have a managed library that contains some System.Drawing drawing code, but
parts of it depend on a Managed C++ library that provides a managed
interface to unmanaged drawing code. Part of the unma... more >>
Changing the look of an existing control
Posted by Chris Dunaway at 6/22/2004 12:02:54 PM
I would like to change the look of an existing control (Group Box) and am
confusing myself as to how to do this. All I want to do is take the
existing Group Box control and change its appearance. All other
functionality I wish to remain the same.
Do I need to create a new class and inherit f... more >>
GDI Font
Posted by DotNetJunkies User at 6/22/2004 7:43:05 AM
Hi,
Im writing to find out if it is possible to read the following text written in Dax Italic using GDI function(s).
Text:
ÂÇÄÃÔÄ ÒÄÑÈÀË
I would appreciate any advice,
Cheers,
Andrew
---
Posted using Wimdows.net NntpNews Component -
Post Made from http://www.DotNe... more >>
In Web Forms bitmap.save(FileName) don't work
Posted by hfweb at 6/22/2004 7:00:02 AM
Hi,
I'm working with web forms and graphics.
I want to save a bitmap on disk.
bitmap.save(FileName) respond:
[ExternalException (0x80004005): Errore generico in GDI+.]
System.Drawing.Image.Save(String filename, ImageCodecInfo encoder, EncoderParameters encoderParams) +580
System.Drawin... more >>
Graphics.MeasureString - varying results?
Posted by Yaron at 6/21/2004 9:14:27 PM
Hi,
I made a procedure which receives a Graphics parameter, and with that Graphics parameter, performs various things. The area of confusion here is that when I pass the procedure a Graphics object created by a Panel, and use the MeasureString() method, I get a different width than when I pass up... more >>
LinearGradientBrush
Posted by Stephan Scheidl at 6/21/2004 12:40:16 PM
I use a LinearGradientBrush to fill a rectangle. Now I want to know what
color was used on lets say pixel (5,5) in the rectangle. Is there a way to
get the color without using getPixel?
... more >>
Setting the Region causes continual repaint!
Posted by John Mark Howell at 6/21/2004 9:12:47 AM
I have an owner drawn control and am simply creating an elliptical label. I
have the following in the constructor:
<code>
SetStyle(ControlStyles.SupportsTransparentBackColor
|ControlStyles.UserPaint
|ControlStyles.AllPaintingInWmPaint
|ControlStyles.Opaque, true);
Ba... more >>
Drawing image with the original size
Posted by Camilo Telles at 6/20/2004 5:14:01 PM
Sirs,
I have an image with 2160x1440 pixel and 230 dpi. When I print it using Graphics.DrawImage I get one image of 901x601 pixels.
This is exactly the result of the folowing operation:
DisplayX = ImageX/ResolutionImageX*ResolutionDisplayX
901 = 2160/230*96
DisplayY = ImageY/ResolutionIm... more >>
Boxing/Deboxing Bitmaps Problem
Posted by Andrew Cook at 6/20/2004 4:00:02 PM
I am using Microsoft Visual Basic .net 2002 Standard. I am coding an application which loads in data from a compressed file. One of the items in the file is a raw RGB565 bitmap, at 800x600 pixels. In a previous version of my app, I used Bitmap.SetPixel() but performance got to be an issue as it took... more >>
Creation of multiple irregularly shaped areas on a Winform
Posted by B. Chernick at 6/20/2004 11:16:09 AM
I remember seeing a demo years ago of a web technique in which it was possible to map out multiple irregularly shaped areas (hotspots? maps?) for use as links. Is there any way a similar effect could be created in Winforms? I already know how to create an irregularly shaped control for runtime but... more >>
Speed of drawing to bitmap varies with bitmap size
Posted by Bert Hyman at 6/19/2004 3:42:52 PM
This is in C#...
I create a Bitmap sized to fit a form, do a Graphics.FromImage(...) on
that Bitmap and draw to it. I do a bunch of arithmetic to serially compute
the locations of several hundred points and use ImageList.Draw(...) to
plop one of 10 images at each spot. I've set Imagelist.Trans... more >>
Transparent label over live video stream
Posted by Rodrigo S. Novelli at 6/19/2004 11:42:25 AM
Hello All,
I'm working in a software that captures live video from an ordinary webcam.
This software has a form with a panel which is the preview window. In this
panel is show a preview of what is being captured from the webcam. I wish to
put a label inside this panel, but this label should ... more >>
Metafile.Save
Posted by GMan at 6/17/2004 7:04:18 PM
I'm trying to save a metafile I generate to disk as a enhancemetafile but it
always saves as a PNG file. I make the following call
meta.Save(filename, imageformat.emf)
... more >>
image.getthumbnailimage
Posted by RP at 6/17/2004 6:06:05 PM
Hi all, I have a need of resizing images to a thumbnail size on the fly. I
have tried and used the image.getthumbnailimage api successfully. However I
noticed that it doesnt maintain the aspect ratio of the original image while
doing the resize. So some images do end up looking either stretched o... more >>
Transparent GIF
Posted by Patrick at 6/17/2004 5:13:14 PM
Hi
I'm just fighting since a few days with .NET, but can't find out what is
wrong in my code. I try to generate a transparent GIF, but this does not
work, the background is always black.. this is my code
someone can help me?
patrick
string sAppPath = Request.ServerVariables["APPL_PHYSICA... more >>
Converting an Image to Binary Array Problem
Posted by jeff.washburn NO[at]SPAM tevaneuro.com at 6/17/2004 1:48:10 PM
Hi All,
I have an app that takes a multi-page TIFF produced from our fax
software, and breaks it into pages and the puts each page in a row in
a dataset. I had it writing to files and it worked fine. I want to
have it write to memory instead. The following code runs, but on the
ReadBytes l... more >>
RotateFlipType and PropertyGrid - Bug ???
Posted by BeerBoy at 6/17/2004 11:40:54 AM
I've writte a custom control which has a property of type RotateFlipType (
an enum from System.Drawing). Anyway, in design time when I look at the
property grid for an instance of the control the dropdown list showing
possible values has duplicate entries and some missing ones !!! Does anyone
kn... more >>
graphics.drawstring
Posted by Chris Smith at 6/17/2004 11:34:11 AM
Experienced posters,
Hope I have an easy question for you.
I am using the following code to draw a string;
g.DrawString(BaseStartDate.ToShortDateString, New Font("Tahoma", 6,
FontStyle.Bold), New SolidBrush(Color.Red), X + 2, Height - 9)
My Question is how do I determine how long a stri... more >>
Speeding up Bitmaps Loading
Posted by Perlom at 6/17/2004 11:20:53 AM
I am trying to load a sequence of large bitmaps (720*486) and then loop thru
each pixel and convert its color space form RGB to YCbCr which is used in TV
broadcasting. I'm using VB.NET. Unfortunately, the overall process came up
to be real slow specially when running this on 300 frames (around 3... more >>
Bitmap conversion
Posted by iyuen at 6/17/2004 11:01:16 AM
I'm trying to convert byte array (valid bitmap format) into some bitmaps and
back to byte array again. But when I inspect the content of the array
before and after the conversion they are different. I'm used the following
code to do the conversion. May any of you tell me what's happening?
T... more >>
Image Processing Components
Posted by Andreas Håkansson at 6/17/2004 7:27:44 AM
Hiya!
I'm currently looking for a good image processig component (classes) to use
in
a project. I do not want to controls (winform or webform) since I will be
doing
this with code. I actually do not need my image processing functionality,
mainly
* Resizing
* Cropping
My main n... more >>
Graphing Geographic Data
Posted by John Wright at 6/16/2004 10:59:24 AM
I have a map of my local state and I have a feed I receive on a regular
basis (the feed consists of XML data that gives me geographic coordinates
that I store in my database). We are switching to .NET and we want to make
this real time and available on the web for our remote people to view. I
... more >>
Speeding up GDI+
Posted by Dave at 6/16/2004 9:40:40 AM
I've got an application that allows the end user to draw on an image (lines,
rectangles, ellipses and freehand). The images can be pretty big, they're
taken with a 5mp camera. The drawing works but lags behind the mouse
movements, I've read some posts that suggest caching and other ways to speed
... more >>
ArgumentException received when converting a byte array to bitmap
Posted by iyuen at 6/16/2004 8:33:42 AM
I'm having problems with converting a byte array to an image object~
My byte array is an picture in VB6 StdPicture format. I've used propertybag
to convert the picture into base64Array format in XML, and embedded
the array as some child element in an xml file, i.e.:
<Mask>bHQAAH4AAABCTX4AAA... more >>
Very simple question about HScrollbar
Posted by Sahil Malik at 6/15/2004 7:11:57 PM
I am making a user control.
It has a Hscrollbar,
and a label.
and I have a piece of code that links them together as -
private void hScrollBar1_Scroll(object sender,
System.Windows.Forms.ScrollEventArgs e)
{
label1.Text = hScrollBar1.Value.ToString() ;
}
(Also the relevant event ha... more >>
auto scroll bar and drawing primitives problems
Posted by njp at 6/15/2004 5:12:28 PM
BlankI'm having the following problems with auto scroll bars =
appearing/disappearing on a panel on which I draw different primitives =
(drawn using Bob Powell's code as a base). The panel class and scroll =
bar handling routine are listed below. I call the latter routine =
whenever a primitive ... more >>
Add EXIF Tag to JPEG
Posted by BluDog at 6/15/2004 9:10:53 AM
Hi
I was wandering if anyone knew if it was possible to add custom EXIF
tags (such as Photographer and Title) to a JPEG image, or to modify
the existing tags (such as ImageDescription).
There is an extremely good article on Code Project for reading these
tags, but I cannot find any informat... more >>
Interpolation in graphics.DrawImage
Posted by AndrewEames at 6/15/2004 6:46:01 AM
I'm probably doing something silly here but it seems to me that the Picturebox control in StretchImage mode (and Graphics.DrawImage too for that matter) is interpolating with an "extra" white pixel on the right and bottom of the image.
If you try this, you get a rather surprising result - the ima... more >>
Ellipse Area Focus
Posted by suresh at 6/14/2004 9:14:58 PM
Hi All,
How to select a circular area from an image in .NET.
regards
Suresh
..
... more >>
|