我正在寻找一种算法来适应视口内的边界框(在我的例子中是一个DirectX场景).我知道用于在正交相机中居中定界球的算法,但是对于边界框和透视相机需要相同的算法.我不能只改变视觉因为这个应用程序有FOV作为用户可编辑变量,所以它必须移动相机.
我有大部分数据:
我遇到的问题:
如何找到相机位置,使其尽可能完美地填充视口(例外情况是,如果宽高比远离1.0,它只需要填充其中一个屏幕轴)?
我尝试过其他一些东西:
请帮忙!
我的项目由以下位置的代码组成
C:\Dev\ProjectA
C:\Lib\LibraryB
C:\Lib\LibraryC
Run Code Online (Sandbox Code Playgroud)
目前,这些文件夹中的每一个都是完全独立的Mercurial存储库.项目A一直在变化,图书馆B和图书馆C很少变化.
我现在标记了项目A的每个版本,因为它已经发布,并且(当我记得的时候)在库B和C库中放置了相应的标签.
我可以通过使用子库来改进吗?这需要我将库B和C作为项目A的子目录吗?
如果库B和C必须是项目A的子目录,如果我想启动使用库B的项目D但是根本不属于项目A,我该怎么办?
我想为我的软件添加14天的试用限制.该程序是用Delphi 7编写的.
任何帮助将非常感激.
我在一篇关于Version Insight(http://www.delphifeeds.com/go/s/77066)的博客中读到了(其中包括)JCL没有版本控制下的.dproj文件,我想知道它的优点是什么那会是.
特别是因为我和我的同事开发人员经常通过使用我们自己喜欢的调试设置检查项目文件而互相"错误"(他喜欢优化,我希望它关闭).而且由于Delphi 2007的常规问题,dproj文件被各种错误的依赖项搞砸了.版本控制无论如何都不能帮助这些东西吗?
我们目前正在使用Starteam作为我们的VCS.
我想使用RTTI在设计时而不是运行时检查项目源文件中包含的类型.
据我所知,这是不受支持的,但是这个问题的评论中的讨论表明它可能并且已经有几个Delphi版本.这是我第一次听说这个功能可用但是我一直无法为自己重现它.
这是我的测试示例.它使用一个简单的TListBox后代TMyListBox,它具有一个string属性TypeToExplore,该属性在设置时使用输入的限定类型名称的属性填充列表框.
unit MyListBox;
interface
uses
SysUtils, Classes, Controls, StdCtrls;
type
TMyListBox = class(TListBox)
private
FTypeToExplore : string;
procedure SetTypeToExplore(const inValue: string);
procedure FillWithTypeDetails;
published
property TypeToExplore : string read FTypeToExplore write SetTypeToExplore;
end;
procedure Register;
implementation
uses
RTTI, TypInfo;
procedure TMyListBox.SetTypeToExplore(const inValue: string);
begin
if inValue = FTypeToExplore then
Exit;
FTypeToExplore := inValue;
Clear;
FillWithTypeDetails;
end;
procedure TMyListBox.FillWithTypeDetails;
var
context : TRTTIContext;
theType : TRttiType;
properties …Run Code Online (Sandbox Code Playgroud) 有谁知道如何使用边距和填充字段?
显然它们可以代替Anchors使用,因为FM不支持Anchors.今天早上我一直在和他们一起玩,但无法让他们以我想要的方式行事.例如,我希望将两个按钮锚定到表单的右侧和底部,以便在调整表单大小时按钮随表单移动.
首先这是关于php4Delphi而不是RadPHP(以前的Delphi For PHP).
运用
当试图在IIS/PHP服务器上运行php4Delphi delphi_math.dll示例扩展时,我在C:\ Windows\Temp\php-errors.log文件中看到以下错误.
[15-Jun-2011 17:58:42] PHP警告:PHP启动:无法加载动态库'C:\ Program Files(x86)\ PHP\ext\delphi_math.dll' - 动态链接库(DLL)初始化例行失败.在第0行的未知中
我已经解决了PHP的初始问题,没有找到我的扩展,因此它不是路径样式问题.
我认为php4Delphi 7.2可能不支持最新的PHP 5.3.6.有谁有这个配置为他们工作?
SQLite具有有趣的“功能”,可让您将任何内容存储在任何字段中,而不管其数据类型如何。
http://www.sqlite.org/different.html#typing
我必须读取一些外部创建的SQLite文件,这些文件是通过(ab)使用此“功能”创建的。它们具有定义为VARCHAR(30)的字段,但正在使用该字段存储最多100个字符或更多的字符串。如果直接调用SQLite DLL来存储数据,SQLite会很高兴地做到这一点而不会进行任何修整。
我当前正在使用具有SQLite支持的DevArt UniDAC 3.70.0.19来读取这些文件,但是它在定义字段时会相当尊重字段的大小,因此会创建一个长度为30个字符的TStringField对象。我无法访问超出30个字符限制的所有字符。
我知道所有可用的用于SQLite的Delphi解决方案,但是有人可以告诉我哪一个可以处理此“功能”吗?
我需要在Delphi 2010中实现一个IFilter,它可以搜索Office 2007 docx文件并返回文档中的文本.
ifilter还需要使用IPersistStream接口.
谢谢
我知道在Edittext的左侧部分使文本"消失"的属性维持一行,(singleLine ="true").但是我的问题是当我在显示视图之前填充edittext时...在这种情况下,我的edittexts都出了屏幕...任何想法?谢谢!
这是填充空Edittext时得到的.一切都保持不变,文字在左侧消失
当我从我的数据库预先填充
这是edittext的代码:
<EditText android:id="@+id/InscripChampNom"
android:layout_height="wrap_content" android:textSize="14px"
android:inputType="textPersonName" android:layout_marginRight="20dip"
android:singleLine="true" android:textColor="@color/background"></EditText>
Run Code Online (Sandbox Code Playgroud)
tableLayout定义如下:
<TableLayout android:layout_width="fill_parent"
android:stretchColumns="1" android:layout_height="fill_parent">
Run Code Online (Sandbox Code Playgroud)
我也试过了这个属性
android:layout_width="fill_parent"
Run Code Online (Sandbox Code Playgroud)
和
android:layout_width="wrap_content"
Run Code Online (Sandbox Code Playgroud)
根本没有成功......
也许输入类型和单行之间存在冲突?
编辑这是我的问题的完整代码:
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:scrollbars="vertical" android:background="@color/backgroundzen"
android:layout_gravity="fill" android:layout_height="fill_parent"
android:layout_width="fill_parent" android:paddingLeft="6dip"
android:paddingRight="6dip">
<TableLayout style="@style/LayoutWhiteBgrdFillWrap"
android:paddingLeft="6dip" android:paddingRight="6dip"
android:stretchColumns="1">
<TextView android:id="@+id/NomFormationConference" style="@style/textViewTitleRedzenBold"
android:text="Nom conférence"></TextView>
<TableRow android:layout_margin="2dip">
<TextView android:id="@+id/DateSession" android:textColor="@color/textezenrouge"
android:layout_height="wrap_content" android:layout_width="wrap_content"
android:text="date début"></TextView>
<TextView android:id="@+id/speakerConf" android:textColor="@color/textezenrouge"
android:layout_height="wrap_content" android:layout_width="wrap_content"
android:text="speaker"></TextView>
</TableRow>
<TableRow android:layout_margin="2dip">
<TextView android:id="@+id/InscripNom" android:layout_width="wrap_content"
android:textColor="@color/background" android:layout_height="wrap_content"
android:text="@string/nom" android:textStyle="bold"></TextView>
<EditText android:id="@+id/InscripChampNom"
android:layout_height="wrap_content" android:textSize="14sp"
android:layout_width="fill_parent" android:inputType="textPersonName" …Run Code Online (Sandbox Code Playgroud) 与VCL控件一样,FireMonkey控件似乎没有锚属性.当表单调整大小时,如何使FireMonkey控件自动调整?
我正在尝试编写Delphi Open Tools API工具,用于自动生成和更新放置在数据模块或表单上的组件.我已经可以列出所有组件(每个组件由(IOTAComponent的类)实例表示)并修改它们的属性(setPropByName(...),getPropValueByName(...)).问题是 - 如何创建新组件 - 在Open Tools API代码中,以便将此组件添加到datamodule的形式?
我正在使用IOTAModuleServices API的一部分,我猜这是手头任务的正确部分,不是吗?
delphi ×9
anchor ×2
firemonkey ×2
3d ×1
android ×1
delphi-2007 ×1
design-time ×1
devart ×1
ifilter ×1
iis-7 ×1
licensing ×1
margin ×1
mercurial ×1
opentools ×1
padding ×1
perspective ×1
php ×1
php4delphi ×1
rtti ×1
size ×1
sqlite ×1
starteam ×1
subrepos ×1
zoom ×1