Notifications
Clear all

[Closed] Adding bitmaps?

Hey Guys,
Is it possible to bitmaps together?
Currently im reading in a row of 2 bitmaps, adding them together in a loop and setting that row into my new bitmap. However it takes about 30 seconds to add 2 x2048 textures… and ill be doing this on about 100 objects, which would be about 50mins!

If theres no way inmaxscript ill just do it via c++ SDK.

Cheers

5 Replies

Hello there,

I also had the very same question. I would be very happy if someone would post the answer.

-Thanks

Built-in MAXScript bitmaps methods are good but slow. Do you looked at .Net ? There’s some interesting classes in GDI+.

Yes, in C++ it will be (very) much faster and not difficult to implement. You can create an Utility or a new MAXScript command to perform this operation.

 rdg

I am not sure I understood exactly what you want to do.

Recently I tried something like this in maxscript.
In the end I used aftereffects to stich the bitmaps.

Rename them if they aren’t already a numbered sequence.
Import the sequence into aftereffects and offset the sequence to have the images arranged like you want. Render it.

You can still use maxscript to rename the files to have the right order …

Georg

Compositing bitmaps in Maxscript is slow, I’ve written a couple of functions which scale and composite bitmaps but they are slow on the larger maps. You can try speeding things up a bit by converting your bitmaps to array’s before working on the data in the loops, just make sure you increase your maxscript memory first

As ypuech says, if you’re using max 9, investigate using the GDI+ classes in .net, they’re about a million times faster.

The avguard extension has a function for this, I think it’s called PasteBitmap. It lets you specify the source and destination regions/locations, so it should be able to do what you want.

Martijn