Let's experiment with this thumbnail thing

Let's experiment with this thumbnail thing

Anonymous
Not applicable
109 Views
3 Replies
Message 1 of 4

Let's experiment with this thumbnail thing

Anonymous
Not applicable
Now that we know we can access block preview thumbnails I'd like to perfect
the process. Would anyone care to assist? The first thing we need to figure
out is the problem Tony T. mentioned. I have yet to encounter it but that's
probably because I haven't tested it as thoroughly as he has.

If you come across the "Invalid buffer" message, please email the block in
question. The message only means that there isn't 2088 bytes (or 4176
characters). Since the amount of data representing the bitmap is constant
(32x32 = 1024), it shouldn't be anywhere near difficult to account for the
differences in color depth. But first I have to see them. If you are
interested in *helping*, please email me or respond to this post.

Snide remarks are not solicited, warranted nor wanted.

--
Attitudes are contagious. Is yours worth catching?
http://www.acadx.com
0 Likes
110 Views
3 Replies
Replies (3)
Message 2 of 4

Anonymous
Not applicable
First contribution comes from Tony T. He reported a drawing which produces
failure consistently: "Basic Electronics.dwg"(in your sample\designcenter
folder). It would appear that color depth is not the culprit at all (at
least in this case). When I debugged the error, I found that the length of
the string retrieved was zero: there is no preview data on these blocks. Can
anyone confirm this?

BTW, that does point up somethng I failed to mention: my limited testing
shows that only blocks defined in a drawing with BMAKE (not -BLOCK or
INSERT) will have preview data. Can anyone confirm this as well?

--
Attitudes are contagious. Is yours worth catching?
http://www.acadx.com

Frank Oquendo wrote in message
news:E6529E0C52D74A688300F81D253E587D@in.WebX.SaUCah8kaAW...
> Now that we know we can access block preview thumbnails I'd like to
perfect
> the process. Would anyone care to assist? The first thing we need to
figure
> out is the problem Tony T. mentioned. I have yet to encounter it but
that's
> probably because I haven't tested it as thoroughly as he has.
>
> If you come across the "Invalid buffer" message, please email the block in
> question. The message only means that there isn't 2088 bytes (or 4176
> characters). Since the amount of data representing the bitmap is constant
> (32x32 = 1024), it shouldn't be anywhere near difficult to account for the
> differences in color depth. But first I have to see them. If you are
> interested in *helping*, please email me or respond to this post.
>
> Snide remarks are not solicited, warranted nor wanted.
>
> --
> Attitudes are contagious. Is yours worth catching?
> http://www.acadx.com
>
0 Likes
Message 3 of 4

Anonymous
Not applicable
Tony was right after all. BlockPreview has been amended to correctly handle
monochrome bitmaps as well as 256-color bitmaps.

--
Attitudes are contagious. Is yours worth catching?
http://www.acadx.com
0 Likes
Message 4 of 4

Anonymous
Not applicable
But this still does not handle bitmaps with anything
but 2 or 256 colors. This isn't really a solution, it's
just more hacking.

There's a number of applications, including my own
BlockView, that allow the user to assign their own
bitmaps to block icons (for a very good reason - in
many cases the icons AutoCAD generates are totally
illegible and largely useless).

With BlockView, a user can assign any valid 32 x 32
bitmap with any legal color depth (including true
color), to a block icon.

Your revised code still cannot deal with any of
these, except for monochrome and 256 color bitmaps.

Frank Oquendo wrote:
>
> Tony was right after all. BlockPreview has been amended to correctly handle
> monochrome bitmaps as well as 256-color bitmaps.
>
> --
> Attitudes are contagious. Is yours worth catching?
> http://www.acadx.com
>
> ------------------------------------------------------------------------------------------
> Name: BlockPreview.zip
> BlockPreview.zip Type: Winzip32 File (application/zip)
> Encoding: base64

--

Checkout DWGInfoTip at http://www.caddzone.com/dwginfo.htm

/*********************************************************/
/* Tony Tanzillo Design Automation Consulting */
/* Programming & Customization for AutoCAD & Compatibles */
/* ----------------------------------------------------- */
/* tony.tanzillo@worldnet.att.net */
/* http://www.caddzone.com */
/*********************************************************/
0 Likes