Loading Mesh failed

Just starting out? Need help? Post your questions and find answers here.
Yerrel
User
User
Posts: 14
Joined: Mon Sep 13, 2004 9:15 pm

Loading Mesh failed

Post by Yerrel »

Hoi me again,

Now with the following struggle. :evil: f
I've created a cube in Milkshape 3D and export it as ogr .mesh file-format.
So far so good,,,, But: uuggggghhh

When i try to load the mesh in Purebasic than i get the following:

Specified #Mesh is not initialized....

The Code:

If InitEngine3D()
Add3DArchive("Data\", #PB_3DArchive_FileSystem)

InitKeyboard()
InitSprite()

If OpenScreen(640, 480, 16, "Mesh Test")=0
MessageRequester("Error", "Could not open 640x480x16 scrren")
EndIf


LoadMesh(0,"cube.mesh")

CreateMaterial(1,LoadTexture(1,"clouds.jpg"))
CreateEntity (0, MeshID(0), MaterialID(1))

The following rest of code is taken from the mesh examples source:

Repeat

ClearScreen(0, 0, 0)

If ExamineKeyboard()

If KeyboardPushed(#PB_Key_Left)
KeyX = -1
ElseIf KeyboardPushed(#PB_Key_Right)
KeyX = 1
Else
KeyX = 0
EndIf

If KeyboardPushed(#PB_Key_Up)
KeyY = -1
ElseIf KeyboardPushed(#PB_Key_Down)
KeyY = 1
Else
KeyY = 0
EndIf

If KeyboardPushed(#PB_Key_PageUp)
RollZ = 3
Else
RollZ = 0
EndIf

If KeyboardPushed(#PB_Key_Add)
Frame.f+0.005
EndIf

EndIf

If ExamineMouse()
MouseX = -MouseDeltaX()/10
MouseY = -MouseDeltaY()/10
EndIf

RotateEntity(0, 1, 0, 0)

RotateCamera(0, MouseX, MouseY, RollZ)
MoveCamera (0, KeyX, 0, KeyY)

RenderWorld()

FlipBuffers()
Until KeyboardPushed(#PB_Key_Escape)
EndIf

The Data's are organized as follows:
In the map Data: i'v put: cube.mesh and clouds.jpg ( sisze = 256 x 256 )
User avatar
grapy
User
User
Posts: 31
Joined: Sat Sep 06, 2003 9:32 am

Post by grapy »

Seems you have the wrong Ogre Exporters.

These are the right one: OgreExporters-0.11.1.zip

grapy :mrgreen:
Yerrel
User
User
Posts: 14
Joined: Mon Sep 13, 2004 9:15 pm

Post by Yerrel »

grapy wrote:Seems you have the wrong Ogre Exporters.

These are the right one: OgreExporters-0.11.1.zip

grapy :mrgreen:
HoYeah Grapy....

True, i was using the wrong exporters ( had used the new one )... thanks for the link... :wink:
marvin
User
User
Posts: 35
Joined: Sun Jul 18, 2004 1:43 am

when will OGre be updated in PureBasic?

Post by marvin »

When will OGre be updated in PureBasic?

Just need to know an approximate date.

Thanks
Post Reply