如何在程序中保存多张位图为MBM
来源:互联网 发布:人工智能技术体系架构 编辑:程序博客网 时间:2024/05/16 14:34
Try use this....
_LIT(KMbmFile,"C://result.mbm");
_LIT(KBMPFilePath0,"C://facebook.mbm");
hi,
i want to store images in MBM file and, i was suggested to use this fuction.
CFbsBitmap::StoreL
in sdk i read this,
static void StoreL(const TDesC& aFilename,TInt aNumSources,const TDesC* aSources[],TInt32 aSourceIds[]);
i couldn't get how to use the last parameters and what the last one mean
const TDesC* aSources[]- An array of pointers to bitmaps to be stored.
TInt32 aSourceIds[]- An array of identifiers for the bitmaps to be stored.
can anyone help me
thanks
synny
=================================================================================
hi,
Sunny...
u shd do it as this way.......
1.convert imgs to bmp and save them as .mbm using func CFbsbitmap.. saveL()
2.get this path into some buffer and pass them to TDesC* aSources[],
3.for TInt32 aSourceIds[] u can use any ids its ur wish..i used zeros for allimgs..
4.call this storel() function ur mbm is ready to use now...
hope this will help u in creating ur mbm files.......
=======================================================================
Try use this....
_LIT(KMbmFile,"C://result.mbm");
_LIT(KBMPFilePath0,"C://facebook.mbm");
_LIT(KBMPFilePath1,"C://balance.mbm");
TInt32* uniqueIds = new ( ELeave ) TInt32[ 2 ];
CleanupStack::PushL( uniqueIds );
uniqueIds[ 0 ] = 0;
uniqueIds[ 1 ] = 0;
TFileName** filenames = new ( ELeave ) TFileName*[ 2 ];
CleanupStack::PushL( filenames );
filenames[ 0 ] = new (ELeave) TFileName( KBMPFilePath0 );
filenames[ 1 ] = new (ELeave) TFileName( KBMPFilePath1 );
CFbsBitmap::StoreL( KMbmFile, // Filename for new multi-bitmap mbm
2, // Count of files
( const TDesC** )filenames, // bitmaps to be loaded
uniqueIds ); // id's of the bitmaps in MBM files
// Clean resources
delete filenames[ 0 ];
delete filenames[ 1 ];
CleanupStack::PopAndDestroy( filenames );
CleanupStack::PopAndDestroy( uniqueIds );
- 如何在程序中保存多张位图为MBM
- Haxe中保存位图为JPG格式
- 如何在Qt Symbian中保存文件为中文文件名
- 如何动态获取mbm文件名
- 在Android程序中保存全局变量
- 如何在表中保存单引号?
- 如何在"英语聚餐"中保持仪态
- 如何在enum中保存特殊字符串
- 如何在 Outlook Express 中保存密码
- 如何在Android应用程序中保存数据
- 如何在enum中保存特殊字符串
- 如何在视图状态中保存自定义的对象
- 如何在数据库中保存不同类型的文件
- 如何在一个文本文档中保存目录信息
- 如何在 jsp 上输出数据库中保存的文本
- 如何在网页上显示数据库中保存的图片
- 如何在SQLServer中保存和输出图片
- [VB.NET]如何在应用程序中保存密码?在线等
- 信号量
- PHP中条件运算符
- ASP.NET皮肤的用法...
- 如何移植32位程序到64位系统
- spring各种邮件发送
- 如何在程序中保存多张位图为MBM
- 在C#中调用windows API函数
- 洗脑,软件产业工人同样也需要
- shell-删除目录下指定日期前的所有文件
- 解决realplay在ubuntu中没有声音且画面很卡的问题
- HPUX 日志
- Direct3D中常用的数学计算方法总结
- C#中调用Windows API的要点
- IE和Firefox(火狐)在JavaScript方面的不兼容及统一方法