Hi
i want to make animation of my object (i use ogre)
is there any idea how i do that ?
Hi
i want to make animation of my object (i use ogre)
is there any idea how i do that ?
If you have a problem, CUT and PASTE your code. Do not retype or simplify it. Give a COMPLETE and COMPILABLE example of your problem. Otherwise we are all guessing the problem from a fabrication where relevant details are often missing.
Hi
thanks for repling
beh,
yes , i see the links (before you put it her "i made effeort") but there is not like what i want
in my case i have in each frame the position of my objects like that
so i want when i clic to button i see my object in the new positions in each frame (like an animation)Qt Code:
frame[i].object.x//frame[0].object.x=...,frame[1].object.x=.....,............................... frame[i].object.y frame[i].object.zTo copy to clipboard, switch view to plain text mode
well, I dont know about ogre, but if you were rendering by qt, then use a basic index for time, or use http://qt-project.org/doc/qt-4.8/qtimeline.html.
then reimplement paintevent to draw your objects using the time index.
Qt Code:
void widget::paintEvent(qpaintevent * evt) { int time = getTime(); // get time index from qtimeline or some other counter // for each object in frame drawObjectAt(object, frame[tim].object.x, frame[tim].object.y, frame[tim].object.z); // func that draws an object at specific location. }To copy to clipboard, switch view to plain text mode
btw, it looks strange that you seem to have object as a property on frame. Normally animation would be a function of a model or model id.
also might be useful
http://www.developer.nokia.com/Commu...TimeLine_in_Qt
If you have a problem, CUT and PASTE your code. Do not retype or simplify it. Give a COMPLETE and COMPILABLE example of your problem. Otherwise we are all guessing the problem from a fabrication where relevant details are often missing.
Bookmarks