Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

x3206 implicit truncation of vector type

649 views
Skip to first unread message

Richy

unread,
Mar 10, 2010, 4:51:21 PM3/10/10
to
Ever since upgrading to the February 2010 Slimdx and equivalent
DirectX
SDK I have been getting this compilation error message:

x3206 implicit truncation of vector type

This happens EVERY time I compile a shader with an error, regardless
of
the error itself. It is extremely frustrating as it provides no
indication
of the type of error. Apparently this is a Microsoft thing and is by
design.

But the warning is frustrating beyond belief. It certainly can't be
described as a feature, because like I said, no
matter what the error is, it ALWAYS gives the X3206 message and there
is no way of finding out what the error
really is without going through the code character by character.
Previously a meaningful message indicating
the error would be given, but not any more. Miss a ; off a line, it
gives the error. Misspell a variable name
(so the variable is no longer defined), it gives the same message.
Misspell a keyword, same message. Example:

float4(1,1,1)

would previously give a message similar to 'function does not take
three parameters', now it just gives X3206.
The compiler doesn't give any other error messages anymore for some
reason.

Anybody else having this issue?

Richard

Richard [Microsoft Direct3D MVP]

unread,
Mar 18, 2010, 5:14:42 AM3/18/10
to
[Please do not mail me a copy of your followup]

I can't reproduce this. I took one of the SDK .fx files, copied it to
a new name. Then I edited that file to change the name of a variable
and compiled it with fxc from the Feb 2010 SDK. I got the error you'd
expect:

F:\test.fx(121,13): error X3004: undeclared identifier 'vTex0blah'

What happens when you run fxc from the command-line?

What shader profile are you targeting?
--
"The Direct3D Graphics Pipeline" -- DirectX 9 draft available for download
<http://legalizeadulthood.wordpress.com/the-direct3d-graphics-pipeline/>

Legalize Adulthood! <http://legalizeadulthood.wordpress.com>

Richy

unread,
Mar 20, 2010, 10:12:21 PM3/20/10
to

I am using profile fx_4_ 0 / DirectX 10 and this is the output from a
compilation. The change I made to an otherwise perfect shader was

output.pos = pos;

to

output.posxx = pos; // just to force it to error, the output gives no
indication of the type of error though, just X3206, and it throws up
lots of similar errors as a result of this one

Richy

D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(703,40): warning X3206: implicit truncation of
vector type
D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(753,39): warning X3206: implicit truncation of
vector type
D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(755,18): warning X3206: 'mul': implicit
truncation of vecto
r type
D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(755,11): warning X3206: implicit truncation of
vector type
D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(757,23): warning X3206: 'mul': implicit
truncation of vecto
r type
D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(757,11): warning X3206: implicit truncation of
vector type
D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(1372,39): warning X3206: 'SimplexNoise3D':
implicit truncat
ion of vector type
D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(1372,23): warning X3206: implicit truncation of
vector type

D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(1377,43): warning X3206: 'SimplexNoise3D':
implicit truncat
ion of vector type
D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(1377,23): warning X3206: implicit truncation of
vector type

D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(1585,13): warning X3206: implicit truncation of
vector type

D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(1833,10): warning X3206: implicit truncation of
vector type

D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(2018,11): warning X3206: implicit truncation of
vector type

D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(2060,10): warning X3206: implicit truncation of
vector type

D:\Backup\VB.NET\DirectX10\MyEditor\bin\x86\Debug\Projects\Terrain
Test 2\Effect
s\TerrainOriginal.fx(2108,10): error X3018: invalid subscript 'posxx'

compilation failed; no code produced


On Mar 18, 7:14 pm, legalize+jee...@mail.xmission.com (Richard

Richy

unread,
Mar 20, 2010, 10:17:37 PM3/20/10
to

I just noticed the error IS given but right at the very end of the
other errors. I generally don't use fxc but use the FromFile method on
an Effect object. The error message returned by that used to give the
actual error right at the start (no doubt fxc used to too), I've just
checked the compilation errors output from the FromFile method and it
does actually give the error, but right at the very end after 13
occurrences of the useless X3206 warning.
0 new messages