|
I've just read through the 1st 13 chapters of Tom Millers MDX9 book.
The examples given basicly leave you with a single looping animation from a .x file.
Are there tutorials or guides out there on how to get a better level of interaciton with the .x animation?
For example a way to play different animations on a key press or only play a certain amount of frames from the .x file?
Thanks
|
|
|
|
|
IIRC, keep reading.
There's also a couple of examples in the DX9 SDK that describe what you are looking for. You can download it (if you haven't already) from http://msdn.microsoft.com/directx[^].
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
IIRC, keep reading.
Nope scanned ahead and 13 is the last chapter covering 3D... after that its sound, 2d graphics, user input and networking then the back cover.
I cant find an example in the SDK either that shows how to pull various animations out of a .x file any clue as to which one i should be looking at?
|
|
|
|
|
I don't have the book with me at work, but I'm fairly sure (hence, "IIRC") it described pulling animations out of meshes. I'll have to look tonight.
As far as the SDK samples go I was mistaken. Upon further investigation a mesh was not used to animate the helicopter (in the August refresh). The rest are just applying transforms to the world for a loaded mesh.
This posting is provided "AS IS" with no warranties, and confers no rights.
Software Design Engineer
Developer Division Sustained Engineering
Microsoft
[My Articles] [My Blog]
|
|
|
|
|
Yes the example shows you how to make an animation loop from a.x file with only 1 animation in it.
It doesnt really stop and say: "if you only want to play frames x to y do this" or "If you want to play animations X or y do this"
Ihave yet to re-read it and impliment the code (i read it once and browse the source code then re-read and do it my self) but from what i've read it basicaly just plays the animation in a loop...
What would have been handy is if the book used a model with more animations as an example and showed you how to activate each one indervidualy .eg press W to start walk animation. C to srart crouching J to start jumping..... would be a much more apt example of how to use mesh animaiton in games.or maybe im asking to much
|
|
|
|
|
Having looked through the C++ samples on the DX9 SDK it seems what im after is a C# version of the MultiAnimation demo. (the one where you add models to a scene then they move around firing off different animations like walk, run, loiter, wave etc)
Any one know of a link to any thing like this?
Thanks
|
|
|
|
|
Hi !
I'm looking for Voice Recognition SDK's... if you have some ideas or testing someone ...
Thanks in advance
|
|
|
|
|
try microsofts speach sdk
|
|
|
|
|
Is there a "Tapi" code in C#
|
|
|
|
|
There is no TAPI support in the .NET BCL. You'll have to go through the pain of P/Invoke'ing all the calls and rewriting all the structures they need in C#. From other answers posted to the same question on CodeProject, it's royal pain in the *** to do. It's been recommended against doing it several times.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Thanx
|
|
|
|
|
|
I have created a multiple client chat window program in which I want to create a new chat form and show it when the client gets the chat request from another client. When the communication socket thread for the client receives the chat request and tries to create a new form and show the form, it is not displayed since the communication socket thread is a worker thread. Can anybody has solution for this?
|
|
|
|
|
You'll have to invoke this, so it's executed in the context of the UI Thread. Take a look at the documentation for the Control.Invoke[^] method.
www.troschuetz.de
|
|
|
|
|
The easiest way is to let the UI thread do the display. Here is an example of how I handle an event fired from a working thread in my code. I learned this technique from a set of excellent articles by Chris Sells on MSDN. The key is using the forms InvokeRequired property and Invoke method.
private void RaiseProgram(object sender, EventArgs args)
{
if (InvokeRequired)
{
object[] objs = new object[]{sender,args};
this.Invoke(new EventHandler(RaiseProgram),objs);
return;
}
textBox1.Text = RunOnce.OtherAttemptCount.ToString();
if (this.WindowState == FormWindowState.Minimized)
{
this.WindowState = FormWindowState.Normal;
}
RunOnce.BringFormToFront(this);
}
|
|
|
|
|
I have created an application. Here I am giving the code for the form file in the application in which I am trying to show a new form when the timer expires after 2 seconds. But the form is not displayed properly. When the button on the form is clicked it properly shows a new form. So please let me know what is going wrong here?And how to correct that.
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
using System.Timers;
using System.Threading;
using System.Windows.Forms.Design;
namespace WindowsApplication1
{
public class Form1 : System.Windows.Forms.Form
{
private System.Windows.Forms.Button button1;
private System.ComponentModel.Container components = null;
public Form1()
{
InitializeComponent();
}
protected override void Dispose( bool disposing )
{
if( disposing )
{
if (components != null)
{
components.Dispose();
}
}
base.Dispose( disposing );
}
#region Windows Form Designer generated code
private void InitializeComponent()
{
this.button1 = new System.Windows.Forms.Button();
this.SuspendLayout();
//
// button1
//
this.button1.Location = new System.Drawing.Point(120, 152);
this.button1.Name = "button1";
this.button1.TabIndex = 0;
this.button1.Text = "button1";
this.button1.Click += new System.EventHandler(this.button1_Click);
//
// Form1
//
this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
this.ClientSize = new System.Drawing.Size(292, 266);
this.Controls.Add(this.button1);
this.Name = "Form1";
this.Text = "Form1";
this.ResumeLayout(false);
}
#endregion
///
/// The main entry point for the application.
///
[STAThread]
static void Main()
{
// Create a new Timer with Interval set to 2 seconds.
System.Timers.Timer aTimer = new System.Timers.Timer(2000);
aTimer.Elapsed += new ElapsedEventHandler(OnTimedEvent);
// Only raise the event the first time Interval elapses.
aTimer.AutoReset = false;
aTimer.Enabled = true;
Form1 oForm1 = new Form1();
Application.Run(oForm1);
}
// Specify what you want to happen when the event is raised.
private static void OnTimedEvent(object source, ElapsedEventArgs e)
{
Form1 oForm1 = new Form1();
oForm1.Show();
}
private void button1_Click(object sender, System.EventArgs e)
{
//fnCreate();
Form1 oForm1 = new Form1();
oForm1.Show();
}
}
}
|
|
|
|
|
You are having a UI Threading problem. This will fix your current issue but I don't like the whole solution.
You are very dependent upon the line Application.Run(). That is where the UI thread enters the message loop. I would make the timer dependent upon the creation of Form1. It would still have to be static so that you do not create another each time the form loads. I am not quite sure what you are trying to accomplish so I didn't change your current pattern too much here.
static Form1 mainWindow = null;
[STAThread]
static void Main()
{
System.Timers.Timer aTimer = new System.Timers.Timer(2000);
aTimer.Elapsed += new ElapsedEventHandler(OnTimedEvent);
aTimer.AutoReset = false;
aTimer.Enabled = true;
mainWindow = new Form1();
Application.Run(mainWindow);
}
private static void OnTimedEvent(object source, ElapsedEventArgs e)
{
if (mainWindow != null)
{
mainWindow.button1_Click(mainWindow,EventArgs.Empty);
}
}
private void button1_Click(object sender, System.EventArgs e)
{
if (InvokeRequired)
{
object[] objs = new object[]{sender,e};
this.Invoke(new EventHandler(button1_Click),objs);
return;
}
Form1 oForm1 = new Form1();
oForm1.Show();
}
|
|
|
|
|
Thank you for the help. That worked perfectly. I know that the application I have created was very crude one but it was the one to help me in the real problem.
Actually as I had written in the first mail that I was having problem to create form when I get the chat request in a chat application where I was unable to diplay the form properly. It worked when I made some changes getting the information from your help. Thanks again.
|
|
|
|
|
Glad I could help - I learned from the master Chris Sells. He has written a series of 3 articles on the subject for Microsoft. They are very clear and understandable.
Search for: "Safe, Simple Multithreading in Windows Forms"
on: msdn.microsoft.com
|
|
|
|
|
i'm doing a test program and i have many variables.
i looking for a way to classifed the variable according to multi subject
for example: var (x,y,z,w)
group PA : variable related - x,y;
group PLL : variable related - y,w;
group Attenuator : variable related - x,z;
|
|
|
|
|
Hy,
I want to create a Remoting server but all examples I've found shows
how to create a console application. I want my server in a windows service.
The problam is that the process has to be running after the command
RemotingConfiguration.Configure(); and I cannot use Console.readline().
Anyone could show me an example of how to create a .NET Remoting Server using a windows service.
Thanks.
|
|
|
|
|
Hi!
It doesn't matter whether the service is run as a console application or as a windows service.
The only reason for Console.ReadLine() in the samples you've found is that otherwise the application immediately quits and the server will be disposed off.
When you're doing the exact same things in a windows service, the executable is running while the service is running and the remoting server can be shut down by stopping the service.
Configure your remoting server in the Start event of your service and you should be fine.
Regards,
mav
|
|
|
|
|
I actually did this and it works fine, but I ran into one additional problem. I am using a singleton object with essentially an infinite life time. When the service is stopped, The system still seems to think the remote object is registered and allows a proxy to be generated. Now when the client uses the proxy, it get's an exception. I can't find an unregister function in the remoting class. Is there anyway to make the remote object go completely away?
C LaMorticella
Client Instant Access
|
|
|
|
|
Hi
I'm a beginner, but this should still be a simple task. I want to insert some data to my access database. I can run my project, but when I try to insert the data this error message appears: "Operation must use an updateable query"
This is my code:
OleDbConnection conInsertNews;
string strInserNewst;
OleDbCommand cmdInsert;
conInsertNews = new OleDbConnection( "PROVIDER=Microsoft.....);
strInsertNews = "INSERT INTO Test ( Name, Number, Adress ) VALUES ( 'Bob' , '8' , 'Str A' )";
cmdInsertNews = new OleDbCommand( strInsertNews, conInsertNews );
conInsertNews.Open();
cmdInsertNews.ExecuteNonQuery();
conInsertNews.Close();
Can anyone help me with this?
Thanks!!
Searcher
|
|
|
|
|
Okay i'm new to databinding and need to learn how to get information from the database, heres my code, howcome nothing gets returned?
<%@ Page language="c#" Codebehind="SalesLeadsLogin.aspx.cs" AutoEventWireup="false" Inherits="SalesLeadManagement.SalesLeadsLogin" %><br />
<%@ Import Namespace="System.Data" %><br />
<%@ Import Namespace="System.Data.OleDb" %><br />
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" ><br />
<HTML><br />
<HEAD><br />
<title>Colley's Sales Lead Management</title><br />
<meta content="Microsoft Visual Studio .NET 7.1" name="GENERATOR"><br />
<meta content="C#" name="CODE_LANGUAGE"><br />
<meta content="JavaScript" name="vs_defaultClientScript"><br />
<meta content="http://schemas.microsoft.com/intellisense/ie5" name="vs_targetSchema"><br />
<script language="C#" runat="server"><br />
protected void Page_Load(Object sender, EventArgs e)<br />
{<br />
OleDbConnection LoginConnection = new OleDbConnection(@"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\salesleadmgmt.mdb");<br />
OleDbDataAdapter LoginCommand = new OleDbDataAdapter("select * from UsrInfo" ,LoginConnection);<br />
<br />
<br />
DataSet LoginSet = new DataSet();<br />
LoginCommand.Fill(LoginSet, "UsrInfo");<br />
<br />
LoginGrid.DataSource=LoginSet.Tables["UsrInfo"].DefaultView;<br />
LoginGrid.DataBind();<br />
}<br />
<br />
<br />
</script><br />
</HEAD><br />
<body MS_POSITIONING="GridLayout"><br />
<form id="Form1" runat="server"><br />
<br />
<asp:DataGrid id="LoginGrid" style="Z-INDEX: 105; LEFT: 408px; POSITION: absolute; TOP: 256px"<br />
runat="server" BackColor="#6699CC"></asp:DataGrid></P><br />
</form><br />
</body><br />
</HTML>
|
|
|
|